diff --git a/advanced.js b/advanced.js index 0e8c0e10c..271f194c2 100644 --- a/advanced.js +++ b/advanced.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),K5)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var J5="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ss=null;function hf(a){if(ss==null&&(ss=J5.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),hn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ss=null,new Error("BIP39 Wordlist for en (English) FAILED")}var ol=class extends hn{constructor(){super("en")}getWord(e){return hf(this),ss[e]}getWordIndex(e){return hf(this),ss.indexOf(e)}},ul=new ol;hn.register(ul);var bi={en:ul};var xf="hdnode/5.7.0";var os=new E(xf),$5=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),Q5=ve("Bitcoin seed"),xr=2147483648;function gf(a){return(1<=256)throw new Error("Depth too large!");return bf(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,me(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new It(hr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~xr));let n=new Uint8Array(37);if(e&xr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(ca(Xn.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=Uo(F.from(r).add(this.privateKey).mod($5)):l=new cn(W(r))._addPoint(this.publicKey);let p=t,f=this.mnemonic;return f&&(p=Object.freeze({phrase:f.phrase,path:t,locale:f.locale||"en"})),new It(hr,o,l,this.fingerprint,Uo(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=xr)throw new Error("invalid path index - "+r);n=n._derive(xr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=xr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(ca(Xn.sha512,Q5,n));return new It(hr,Uo(i.slice(0,32)),null,"0x00000000",Uo(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=dl(n),e=gi(br(e,n),n),It._fromSeed(ll(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return It._fromSeed(e,null)}static fromExtendedKey(e){let t=fa.decode(e);(t.length!==82||bf(t.slice(0,78))!==e)&&os.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new It(hr,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new It(hr,W(o.slice(1)),null,i,s,r,n,null)}return os.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function ll(a,e){e||(e="");let t=ve("mnemonic"+e,Gt.NFKD);return xi(ve(a,Gt.NFKD),t,2048,64,"sha512")}function br(a,e){e=dl(e),os.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=gf(s);if((j(Xt(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function gi(a,e){if(e=dl(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&X5(8-n)),n+=3);let i=a.length/4,r=j(Xt(a))[0]&gf(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function Tf(a,e){try{return br(a,e),!0}catch{}return!1}function vf(a){return(typeof a!="number"||a<0||a>=xr||a%1)&&os.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var wf="random/5.7.0";var pl=new E(wf);function Y5(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var _f=Y5(),Vo=_f.crypto||_f.msCrypto;(!Vo||!Vo.getRandomValues)&&(pl.warn("WARNING: Missing strong random number source"),Vo={getRandomValues:function(a){return pl.throwError("no secure random source avaialble",E.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Yn(a){(a<=0||a>1024||a%1||a!=a)&&pl.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Vo.getRandomValues(e),j(e)}function us(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var cl=kn(fl());var jo="json-wallets/5.7.0";function ha(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function gr(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),M=new xa.default.Counter(x),J=new xa.default.ModeOfOperation.ctr(O,M),$=j(J.encrypt(i)),de=fe(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:Af(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(f).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=Yn(16),N=new xa.default.Counter(R),q=new xa.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+gr(I.getUTCMonth()+1,2)+"-"+gr(I.getUTCDate(),2)+"T"+gr(I.getUTCHours(),2)+"-"+gr(I.getUTCMinutes(),2)+"-"+gr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function Df(a,e,t){if(Ho(a)){t&&t(0);let n=hl(a,e);return t&&t(1),Promise.resolve(n)}return qo(a)?Nf(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function Of(a,e){if(Ho(a))return hl(a,e);if(qo(a))return Pf(a,e);throw new Error("invalid JSON wallet")}var Bf="wallet/5.7.0";var Ff=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Tr=new E(Bf);function ax(a){return a!=null&&ie(a.privateKey,32)&&a.address!=null}function ix(a){let e=a.mnemonic;return e&&e.phrase}var Sn=class extends St{constructor(e,t){if(super(),ax(e)){let n=new cn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",mn(this.publicKey)),this.address!==ce(e.address)&&Tr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),ix(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||ma,locale:i.locale||"en"}));let r=this.mnemonic,s=It.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);mn(s.privateKey)!==this.address&&Tr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(cn.isSigningKey(e))e.curve!=="secp256k1"&&Tr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new cn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",mn(this.publicKey))}t&&!$t.isProvider(t)&&Tr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Sn(this,e)}signTransaction(e){return Ce(e).then(t=>{t.from!=null&&(ce(t.from)!==this.address&&Tr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(fe(as(t)));return as(t,n)})}signMessage(e){return Ff(this,void 0,void 0,function*(){return jr(this._signingKey().signDigest(ar(e)))})}_signTypedData(e,t,n){return Ff(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,r=>(this.provider==null&&Tr.throwError("cannot resolve ENS names without a provider",E.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return jr(this._signingKey().signDigest(bt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),vl(this,e,t,n)}static createRandom(e){let t=Yn(16);e||(e={}),e.extraEntropy&&(t=j(Ie(fe(ye([t,e.extraEntropy])),0,16)));let n=gi(t,e.locale);return Sn.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return Df(e,t,n).then(i=>new Sn(i))}static fromEncryptedJsonSync(e,t){return new Sn(Of(e,t))}static fromMnemonic(e,t,n){return t||(t=ma),new Sn(It.fromMnemonic(e,null,n).derivePath(t))}};function Lf(a,e){return ci(ar(a),e)}function Uf(a,e,t,n){return ci(bt.hash(a,e,t),n)}var ta={};zi(ta,{AlchemyProvider:()=>Er,AlchemyWebSocketProvider:()=>Ts,AnkrProvider:()=>vs,BaseProvider:()=>ea,CloudflareProvider:()=>ws,EtherscanProvider:()=>_s,FallbackProvider:()=>As,Formatter:()=>Y,InfuraProvider:()=>Ir,InfuraWebSocketProvider:()=>Ms,IpcProvider:()=>Dl,JsonRpcBatchProvider:()=>ru,JsonRpcProvider:()=>Yt,JsonRpcSigner:()=>kr,NodesmithProvider:()=>Is,PocketProvider:()=>Cs,Provider:()=>$t,Resolver:()=>_r,StaticJsonRpcProvider:()=>gs,UrlJsonRpcProvider:()=>Ct,Web3Provider:()=>Ss,WebSocketProvider:()=>Ta,getDefaultProvider:()=>su,getNetwork:()=>ls,isCommunityResourcable:()=>kl,isCommunityResource:()=>fs,showThrottleMessage:()=>Zn});var Vf="networks/5.7.1";var jf=new E(Vf);function rx(a){return a&&typeof a.renetwork=="function"}function ba(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return ba(t)},e}function Wo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return Wo(a,n)},t}var Hf={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:ba("homestead")},qf={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:ba("ropsten")},Gf={chainId:63,name:"classicMordor",_defaultProvider:Wo("https://www.ethercluster.com/mordor","classicMordor")},zo={unspecified:{chainId:0,name:"unspecified"},homestead:Hf,mainnet:Hf,morden:{chainId:2,name:"morden"},ropsten:qf,testnet:qf,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:ba("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:ba("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:ba("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:ba("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Wo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Gf,classicTestnet:Gf,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Wo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:ba("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:ba("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ls(a){if(a==null)return null;if(typeof a=="number"){for(let n in zo){let i=zo[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=zo[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=zo[a.name];if(!e)return typeof a.chainId!="number"&&jf.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&jf.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(rx(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var zf="web/5.7.1";var sx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Wf(a,e){return sx(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var ox=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Rn=new E(zf);function Kf(a){return new Promise(e=>{setTimeout(e,a)})}function Oa(a,e){if(a==null)return null;if(typeof a=="string")return a;if(ia(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Jt(a)}catch{}return W(a)}return a}function ux(a){return ve(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function wl(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Rn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Rn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},f=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Rn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(f=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Rn.throwError("basic authentication requires a secure https url",E.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+nr(ve(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?tr(_[3]):ux(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Rn.throwError("processing response error",E.errors.SERVER_ERROR,{body:Oa(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(M,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Rn.makeError("timeout",E.errors.TIMEOUT,{requestBody:Oa(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return ox(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Rn.throwError("bad response",E.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Oa(H,U.headers?U.headers["content-type"]:null),requestBody:Oa(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let M=yield t(H,U);return S.cancel(),M}catch(M){if(M.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Jt(r))}catch(l){Rn.throwError("invalid JSON",E.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=ve(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return wl(a,i,n)}function Nn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(f){if(f!==void 0)s()&&t(f);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(f){s()&&n(f)})}p()})}var Il=kn(Xf());var Ae="providers/5.7.2";var ys=new E(Ae),Y=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),f=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:Y.allowNull(this.accessList.bind(this),null),blockHash:Y.allowNull(s,null),blockNumber:Y.allowNull(l,null),transactionIndex:Y.allowNull(l,null),confirmations:Y.allowNull(l,null),from:t,gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),gasLimit:n,to:Y.allowNull(t,null),value:n,nonce:l,data:r,r:Y.allowNull(this.uint256),s:Y.allowNull(this.uint256),v:Y.allowNull(l),creates:Y.allowNull(t,null),raw:Y.allowNull(r)},e.transactionRequest={from:Y.allowNull(t),nonce:Y.allowNull(l),gasLimit:Y.allowNull(n),gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),to:Y.allowNull(t),value:Y.allowNull(n),data:Y.allowNull(f),type:Y.allowNull(l),accessList:Y.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:Y.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:Y.allowNull(this.address,null),from:Y.allowNull(this.address,null),contractAddress:Y.allowNull(t,null),transactionIndex:l,root:Y.allowNull(o),gasUsed:n,logsBloom:Y.allowNull(r),blockHash:s,transactionHash:s,logs:Y.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:Y.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:Y.allowNull(n),status:Y.allowNull(l),type:p},e.block={hash:Y.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:Y.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:Y.allowNull(t),extraData:r,transactions:Y.allowNull(Y.arrayOf(s)),baseFeePerGas:Y.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=Y.allowNull(Y.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:Y.allowNull(i,void 0),toBlock:Y.allowNull(i,void 0),blockHash:Y.allowNull(s,void 0),address:Y.allowNull(t,void 0),topics:Y.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:Y.allowNull(l),blockHash:Y.allowNull(s),transactionIndex:l,removed:Y.allowNull(this.boolean.bind(this)),address:t,data:Y.allowFalsish(r,"0x"),topics:Y.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return sn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():ys.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ce(e)}callAddress(e){if(!ie(e,32))return null;let t=ce(Ie(e,12));return t===po?null:t}contractAddress(e){return li(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return Un(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Nt(n)!==32?ys.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return me(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=Y.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return Y.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=Y.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ie(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ie(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return No(e)}receiptLog(e){return Y.check(this.formats.receiptLog,e)}receipt(e){let t=Y.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&ys.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):ys.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&ys.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return Y.check(this.formats.filter,e)}filterLog(e){return Y.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function kl(a){return a&&typeof a.isCommunityResource=="function"}function fs(a){return kl(a)&&a.isCommunityResource()}var Yf=!1;function Zn(){Yf||(Yf=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},he=new E(Ae),hx=10;function Zf(a){return a==null?"null":(Nt(a)!==32&&he.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function ec(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[Zf(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return Zf(e)}).join("&")}function xx(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function wr(a){if(typeof a=="string"){if(a=a.toLowerCase(),Nt(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+ec(a);if(wo.isForkEvent(a))throw he.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+ec(a.topics||[])}throw new Error("invalid event - "+a)}function cs(){return new Date().getTime()}function tc(a){return new Promise(e=>{setTimeout(e,a)})}var bx=["block","network","pending","poll"],Cl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=xx(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||bx.indexOf(this.tag)>=0}},gx={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Al(a){return me(F.from(a).toHexString(),32)}function nc(a){return fa.encode(ye([a,Ie(Xt(Xt(a)),0,4)]))}var rc=new RegExp("^(ipfs)://(.*)$","i"),ac=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),rc,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Qo(a,e){try{return Jt(ms(a,e))}catch{}return null}function ms(a,e){if(a==="0x")return null;let t=F.from(Ie(a,e,e+32)).toNumber(),n=F.from(Ie(a,t,t+32)).toNumber();return Ie(a,t+32,t+32+n)}function El(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):he.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function ic(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function Tx(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function sc(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===E.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:kt([e,Ca(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=kt(["0x9061b923",sc([Zr(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&he.throwError("resolver threw error",E.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=ms(r,0)),r}catch(r){if(r.code===E.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?ms(n,0):null})}_getAddress(e,t){let n=gx[String(e)];if(n==null&&he.throwError(`unsupported coin type: ${e}`,E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return nc(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return nc(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=Il.default.toWords(i.slice(2));return o.unshift(s),Il.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===Zi?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===E.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",Al(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&he.throwError("invalid or unsupported coin data",E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return he.throwError("invalid or unsupported content hash data",E.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=ve(e);t=ye([Al(64),Al(t.length),t]),t.length%32!==0&&(t=ye([t,me("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Jt(n)})}},Ml=null,vx=1,ea=class extends $t{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=mt(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):he.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||he.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Nn(()=>this._ready().then(e=>e,e=>{if(!(e.code===E.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return Ml==null&&(Ml=new Y),Ml}static getNetwork(e){return ls(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Pn({url:p,errorPassThrough:!0},f,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return he.throwError(`response not found during CCIP fetch: ${C}`,E.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return he.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,E.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(cs()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=cs(),n=Ce({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=cs();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=vx++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)he.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",he.makeError("network block skew detected",E.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return he.throwError("provider does not support network detection",E.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield tc(0),this._network;let n=he.makeError("underlying network changed",E.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=cs();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,f=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield tc(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{f()||o(he.makeError("timeout exceeded",E.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Un(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Nt(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&he.throwError("Transaction hash mismatch from Provider.sendTransaction.",E.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&he.throwError("transaction failed",E.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Ce(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Ce(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=hx&&he.throwError("CCIP read exceeded maximum redirections",E.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Nt(r)%32===4)try{let s=Ie(r,4),o=Ie(s,0,32);F.from(o).eq(i)||he.throwError("CCIP Read sender did not match",E.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ie(s,32,64)).toNumber(),f=F.from(Ie(s,p,p+32)).toNumber(),x=Ie(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Nn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Nn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Ce({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),Y.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&he.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new _r(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||he.throwError("network does not support ENS",E.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Ca(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ie(e))throw n}typeof e!="string"&&he.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=Qo(yield this.call({to:n,data:"0x691f3431"+Ca(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new _r(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o}try{let o=Qo(yield this.call({to:s,data:"0x691f3431"+Ca(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return he.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new Cl(wr(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=wr(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=wr(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=wr(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=wr(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=wr(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var ga=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Et=new E(Ae),wx=["call","estimateGas"];function xs(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ie(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=xs(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return xs(JSON.parse(a),e)}catch{}return null}function uc(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=xs(e,!0);if(r)return r.data;Et.throwError("missing revert data in call exception; Transaction reverted without a reason string",E.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=xs(e.body,!1);r==null&&(r=xs(e,!1)),r&&Et.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===E.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Et.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Et.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Et.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Et.throwError("legacy pre-eip-155 transactions not supported",E.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),wx.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Et.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function oc(a){return new Promise(function(e){setTimeout(e,a)})}function _x(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function hs(a){return a&&a.toLowerCase()}var Sl={},kr=class extends St{constructor(e,t,n){if(super(),e!==Sl)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Et.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Et.throwError("cannot alter JSON-RPC Signer connection",E.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new Rl(Sl,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Et.throwError("unknown account #"+this._index,E.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>ga(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Et.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Ce({tx:Ce(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Et.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Et.throwError("user rejected transaction",E.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),uc("sendTransaction",s,r)))})}signTransaction(e){return Et.throwError("signing transactions is unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return ga(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Nn(()=>ga(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return ga(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Et.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return ga(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Et.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return ga(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(bt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Et.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return ga(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},Rl=class extends kr{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},kx={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},Yt=class extends ea{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=mt(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return ga(this,void 0,void 0,function*(){yield oc(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=mt(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Et.throwError("could not detect network",E.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Et.throwError("could not detect network",E.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new kr(Sl,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:ct(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Pn(this.connection,JSON.stringify(n),_x).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[hs(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[hs(t.address),t.blockTag]];case"getCode":return["eth_getCode",[hs(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[hs(t.address),me(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=hs(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return ga(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Et.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return uc(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return oc(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(kx);if(t)for(let r in t)t[r]&&(n[r]=!0);Ji(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Un(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=sn(e.accessList)),i}};var Ar=null;try{if(Ar=WebSocket,Ar==null)throw new Error("inject please")}catch{let e=new E(Ae);Ar=function(){e.throwError("WebSockets not supported in this environment",E.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var Pl=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Xo=new E(Ae),Ax=1,Ta=class extends Yt{constructor(e,t){t==="any"&&Xo.throwError("WebSocketProvider does not support 'any' network yet",E.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new Ar(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){Xo.throwError("cannot reset events block on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){Xo.throwError("cannot set polling interval on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return Pl(this,void 0,void 0,function*(){return null})}set polling(e){!e||Xo.throwError("cannot set polling on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=Ax++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return Pl(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return Pl(this,void 0,void 0,function*(){this.websocket.readyState===Ar.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var Ex=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},bs=new E(Ae),gs=class extends Yt{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return Ex(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||bs.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Ct=class extends gs{constructor(e,t){bs.checkAbstract(new.target,Ct),e=mt(new.target,"getNetwork")(e),t=mt(new.target,"getApiKey")(t);let n=mt(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){bs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return bs.throwError("API provider does not support signing",E.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return bs.throwError("not implemented; sub-classes must override getUrl",E.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var dc=new E(Ae),Yo="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",Ts=class extends Ta{constructor(e,t){let n=new Er(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===Yo}},Er=class extends Ct{static getWebSocketProvider(e,t){return new Ts(e,t)}static getApiKey(e){return e==null?Yo:(e&&typeof e!="string"&&dc.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:dc.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===Yo&&Zn(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===Yo}};var Mx=new E(Ae),Zo="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function Ix(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return Mx.throwArgumentError("unsupported network","name",a)}var vs=class extends Ct{isCommunityResource(){return this.apiKey===Zo}static getApiKey(e){return e??Zo}static getUrl(e,t){t==null&&(t=Zo);let n={allowGzip:!0,url:"https://"+Ix(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===Zo&&Zn(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var Cx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},lc=new E(Ae),ws=class extends Ct{static getApiKey(e){return e!=null&&lc.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:lc.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return Cx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var eu=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Ba=new E(Ae);function pc(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Un(W(n)):t==="accessList"?n="["+sn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function Sx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function yc(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function fc(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function Nl(a,e,t){if(a==="call"&&e.code===E.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Ba.throwError("missing revert data in call exception",E.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===E.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Ba.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Ba.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Ba.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Ba.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var _s=class extends ea{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Ba.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return eu(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?yc:Sx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(f,x)=>(this.isCommunityResource()&&Zn(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(f=>`${f}=${r[f]}`).join("&"));let p=yield Pn(o,l,s||yc);return this.emit("debug",{action:"response",request:i,response:ct(p),provider:this}),p})}detectNetwork(){return eu(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return eu(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Nl("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=pc(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Nl("call",r,t.transaction)}}case"estimateGas":{let i=pc(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Nl("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=fc(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=fc(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Ba.throwError("unsupported topic count",E.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Ba.throwError("unsupported topic format",E.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var au=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Ti=new E(Ae);function tu(){return new Date().getTime()}function cc(a){let e=null;for(let t=0;te?null:(n+i)/2}function Mr(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>Mr(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=Mr(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var Rx=1;function hc(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var Px=[E.errors.CALL_EXCEPTION,E.errors.INSUFFICIENT_FUNDS,E.errors.NONCE_EXPIRED,E.errors.REPLACEMENT_UNDERPRICED,E.errors.UNPREDICTABLE_GAS_LIMIT],Nx=["address","args","errorArgs","errorSignature","method","transaction"];function nu(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function Dx(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function Ox(a,e,t){let n=Mr;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=mc(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return mc(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,Mr(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),Mr(i))}:n=function(i){return i==null?null:Mr(i)};break;default:throw new Error("unknown method: "+e)}return Dx(n,a.quorum)}function ks(a,e){return au(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Nn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function Bx(a,e,t,n){return au(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ie(n.blockTag)&&(i=yield ks(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ie(n.blockTag)&&(i=yield ks(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ie(n.blockTag)&&(i=yield ks(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ie(n.blockTag)&&(i=yield ks(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield ks(a,e)),i.getLogs(r)}}return Ti.throwError("unknown method error",E.errors.UNKNOWN_ERROR,{method:t,params:n})})}var As=class extends ea{constructor(e,t){e.length===0&&Ti.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if($t.isProvider(s)){let f=fs(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:f,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=fs(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&Ti.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&Ti.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=cc(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return au(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return cc(e)})}perform(e,t){return au(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(f=>f.hash,f=>f)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=tu(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=Bx(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:nu(_,tu()),request:{method:e,params:ct(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:nu(_,tu()),request:{method:e,params:ct(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:nu(_,null),request:{method:e,params:ct(t)},provider:this}),p+=_.weight}let f=[];i.forEach(_=>{_.done||!_.runner||(f.push(_.runner),_.staller&&f.push(_.staller.getPromise()))}),f.length&&(yield Promise.race(f));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield hc(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return Px.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};Nx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),Ti.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),Ti.throwError("failed to meet quorum",E.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>nu(l)),provider:this})})}};var Dl=null;var iu=new E(Ae),Es="84842078b09946638c03157f83405213",Ms=class extends Ta{constructor(e,t){let n=new Ir(e,t),i=n.connection;i.password&&iu.throwError("INFURA WebSocket project secrets unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===Es}},Ir=class extends Ct{static getWebSocketProvider(e,t){return new Ms(e,t)}static getApiKey(e){let t={apiKey:Es,projectId:Es,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(iu.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),iu.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:iu.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===Es&&Zn(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===Es}};var ru=class extends Yt{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:ct(o),provider:this}),Pn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,f)=>{let x=l[f];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Ol=new E(Ae),Fx="ETHERS_JS_SHARED",Is=class extends Ct{static getApiKey(e){return e&&typeof e!="string"&&Ol.throwArgumentError("invalid apiKey","apiKey",e),e||Fx}static getUrl(e,t){Ol.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Ol.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var xc=new E(Ae),bc="62e1ad51b37b8e00394bda3b",Cs=class extends Ct{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=bc:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:xc.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:xc.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===bc}};var gc=new E(Ae),Lx=1;function Tc(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:Lx++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:ct(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let f=new Error(p.error.message);return f.code=p.error.code,f.data=p.error.data,o(f)}s(p.result)})})}}function Ux(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:ct(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var Ss=class extends Yt{constructor(e,t){e==null&&gc.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Ux(e)):e.sendAsync?i=Tc(e,e.sendAsync.bind(e)):e.send?i=Tc(e,e.send.bind(e)):gc.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var vc=new E(Ae);function su(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new Yt(a);case"ws":case"wss":return new Ta(a);default:vc.throwArgumentError("unsupported URL scheme","network",a)}}let t=ls(a);return(!t||!t._defaultProvider)&&vc.throwError("unsupported getDefaultProvider network",E.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:As,AlchemyProvider:Er,AnkrProvider:vs,CloudflareProvider:ws,EtherscanProvider:_s,InfuraProvider:Ir,JsonRpcProvider:Yt,NodesmithProvider:Is,PocketProvider:Cs,Web3Provider:Ss,IpcProvider:null},e)}var te={};zi(te,{AbiCoder:()=>er,ConstructorFragment:()=>Dt,ErrorFragment:()=>tn,EventFragment:()=>Ht,FormatTypes:()=>ge,Fragment:()=>qt,FunctionFragment:()=>Ot,HDNode:()=>It,Indexed:()=>ua,Interface:()=>Sa,LogDescription:()=>ir,Logger:()=>E,ParamType:()=>pt,RLP:()=>no,SigningKey:()=>cn,SupportedAlgorithm:()=>Xn,TransactionDescription:()=>rr,TransactionTypes:()=>Po,UnicodeNormalizationForm:()=>Gt,Utf8ErrorFuncs:()=>ho,Utf8ErrorReason:()=>Bt,_TypedDataEncoder:()=>bt,_fetchData:()=>wl,_toEscapedUtf8String:()=>Md,accessListify:()=>sn,arrayify:()=>j,base58:()=>fa,base64:()=>Nd,checkProperties:()=>Ji,checkResultErrors:()=>Qi,commify:()=>Cc,computeAddress:()=>mn,computeHmac:()=>ca,computePublicKey:()=>ns,concat:()=>ye,deepCopy:()=>ct,defaultAbiCoder:()=>Xr,defaultPath:()=>ma,defineReadOnly:()=>B,dnsEncode:()=>Zr,entropyToMnemonic:()=>gi,fetchJson:()=>Pn,formatBytes32String:()=>Id,formatEther:()=>Sc,formatUnits:()=>Bl,getAccountPath:()=>vf,getAddress:()=>ce,getContractAddress:()=>li,getCreate2Address:()=>Dy,getIcapAddress:()=>Ny,getJsonWalletAddress:()=>xl,getStatic:()=>mt,hashMessage:()=>ar,hexConcat:()=>kt,hexDataLength:()=>Nt,hexDataSlice:()=>Ie,hexStripZeros:()=>hd,hexValue:()=>Un,hexZeroPad:()=>me,hexlify:()=>W,id:()=>nn,isAddress:()=>Py,isBytes:()=>on,isBytesLike:()=>ia,isHexString:()=>ie,isValidMnemonic:()=>Tf,isValidName:()=>Od,joinSignature:()=>jr,keccak256:()=>fe,mnemonicToEntropy:()=>br,mnemonicToSeed:()=>ll,namehash:()=>Ca,nameprep:()=>Pd,parseBytes32String:()=>Cd,parseEther:()=>Rc,parseTransaction:()=>No,parseUnits:()=>Fl,poll:()=>Nn,randomBytes:()=>Yn,recoverAddress:()=>ci,recoverPublicKey:()=>Ro,resolveProperties:()=>Ce,ripemd160:()=>rs,serializeTransaction:()=>as,sha256:()=>Xt,sha512:()=>sl,shallowCopy:()=>_e,shuffled:()=>us,solidityKeccak256:()=>kc,solidityPack:()=>ou,soliditySha256:()=>Ac,splitSignature:()=>Vn,stripZeros:()=>Zt,toUtf8Bytes:()=>ve,toUtf8CodePoints:()=>Ia,toUtf8String:()=>Jt,verifyMessage:()=>Lf,verifyTypedData:()=>Uf,zeroPad:()=>si});var wc="solidity/5.7.0";var Vx=new RegExp("^bytes([0-9]+)$"),jx=new RegExp("^(u?int)([0-9]*)$"),Hx=new RegExp("^(.*)\\[([0-9]*)\\]$"),qx="0000000000000000000000000000000000000000000000000000000000000000",Cr=new E(wc);function _c(a,e,t){switch(a){case"address":return t?si(e,32):j(e);case"string":return ve(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?si(e,32):j(e)}let n=a.match(jx);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Cr.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),si(e,i/8)}if(n=a.match(Vx),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Cr.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Cr.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+qx).substring(0,66)):e}if(n=a.match(Hx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Cr.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(_c(i,o,!0))}),ye(s)}return Cr.throwArgumentError("invalid type","type",a)}function ou(a,e){a.length!=e.length&&Cr.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(_c(n,e[i]))}),W(ye(t))}function kc(a,e){return fe(ou(a,e))}function Ac(a,e){return Xt(ou(a,e))}var Ec="units/5.7.0";var Mc=new E(Ec),Ic=["wei","kwei","mwei","gwei","szabo","finney","ether"];function Cc(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&Mc.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Bl(a,e){if(typeof e=="string"){let t=Ic.indexOf(e);t!==-1&&(e=3*t)}return Ki(a,e??18)}function Fl(a,e){if(typeof a!="string"&&Mc.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=Ic.indexOf(e);t!==-1&&(e=3*t)}return dn(a,e??18)}function Sc(a){return Bl(a,18)}function Rc(a){return Fl(a,18)}var uu="ethers/5.7.2";var Pc=new E(uu);try{let a=window;a._ethers==null&&(a._ethers=Ll)}catch{}var Dn;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(Dn||(Dn={}));var du;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(du||(du={}));var Sr;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Sr||(Sr={}));var lu;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(lu||(lu={}));var Ul;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Ul||(Ul={}));var Rs;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Rs||(Rs={}));var Ps;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Ps||(Ps={}));var Vl;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(Vl||(Vl={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var zt;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(zt||(zt={}));var Hl="0x12345678",jl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(jl||(jl={}));var vt;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(vt||(vt={}));var we;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(we||(we={}));var ql=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],vi=class{static createInterface(){return new te.Interface(ql)}static connect(e,t){return new oe(e,ql,t)}};xe(vi,"abi",ql);var Gl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],wi=class{static createInterface(){return new te.Interface(Gl)}static connect(e,t){return new oe(e,Gl,t)}};xe(wi,"abi",Gl);var Nc=(a,e)=>{throw new Error(`${e}: ${a}`)},zl=a=>a!=null;var{keccak256:zx,toUtf8Bytes:Wx}=te,{MaxUint256:Kx}=ht;var Ns=a=>te.formatEther(a),Dc=a=>te.parseEther(a),pu=a=>Dc(a[0]),Wl=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(vt.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(zl)},_i=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return Kx;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},Fa=a=>zx(Wx(a));var Rr=async(a,e)=>(await wi.connect(a,e).version()).toNumber(),Kl=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(zl);var{hexDataSlice:Jl}=te,{MaxUint256:Jx}=ht,Oc=a=>{let e=Jl(a,0,3),t=F.from(Jl(a,4,35)),n=F.from(Jl(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Bc=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),Jx,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await _i(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},$x=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Bc(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?na(a,e,t,n[0],i):$x(a,e,t,n,i):Bc(a,e,t,n,i);var{MaxUint256:Fc}=ht,{AddressZero:Qx}=ht;async function Xx(a,e){let t;try{return t=await a.getCapabilityRoles(te.hexZeroPad(e,4)),yu(t)}catch{return[]}}async function Ds(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:f,childSkillIndex:x}=Oc(s),C=vi.connect(r,n.signer||n.provider),_=await Xx(C,p);if(_.includes(vt.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Fc}else{let{skillId:U}=await e.getDomain(f),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Fc;else{let{children:M}=await a.getSkill(l),J=M.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,Qx);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:Yx}=ht,aa=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||Dn.Gnosis;this.endpointUrl=n?.customEndpointUrl||Sr[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await aa.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await aa.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await aa.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let f=p+1,x=await this.colony.getDomain(f);return{domainId:f,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,f=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return f&&(p=f?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return aa.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${Yx}/noProof`,s=await aa.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var _t=a=>Array.from(Array(a-1)).map(e=>e+1);var Lc=10,Jk=_t(Lc),Uc={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},Vc=Lc-1;var jc=6,Xk=_t(jc),Hc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},qc=jc-1;var Gc=7,eA=_t(Gc),zc={1:[],2:[],3:[],4:[],5:[],6:[]},Wc=Gc-1;var Kc=7,aA=_t(Kc),Jc={1:[],2:[],3:[],4:[],5:[],6:[]},$c=Kc-1;var Qc=4,sA=_t(Qc),Xc={1:[],2:[],3:[]},Yc=Qc-1;var Zc=5,dA=_t(Zc),em={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},tm=Zc-1;var nm=2,yA=_t(nm),am={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},im=nm-1;var rm=4,mA=_t(rm),sm={1:[1,2,3],2:[1,2,3],3:[1,2,3]},om=rm-1;var um=7,bA=_t(um),dm={1:[],2:[],3:[],4:[],5:[],6:[]},lm=um-1;var pm=11,vA=_t(pm),$l={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Ql=pm-1;var ym=6,kA=_t(ym),fm={1:[],2:[],3:[],4:[],5:[]},cm=ym-1;var La=(a,e,t)=>{switch(a){case we.CoinMachine:{let n=Uc[e];return!!n&&!n.includes(t)}case we.EvaluatedExpenditure:{let n=Hc[e];return!!n&&!n.includes(t)}case we.FundingQueue:{let n=zc[e];return!!n&&!n.includes(t)}case we.IVotingReputation:{let n=$l[e];return!!n&&!n.includes(t)}case we.OneTxPayment:{let n=Jc[e];return!!n&&!n.includes(t)}case we.ReputationBootstrapper:{let n=Xc[e];return!!n&&!n.includes(t)}case we.StagedExpenditure:{let n=am[e];return!!n&&!n.includes(t)}case we.StakedExpenditure:{let n=em[e];return!!n&&!n.includes(t)}case we.StreamingPayments:{let n=sm[e];return!!n&&!n.includes(t)}case we.TokenSupplier:{let n=dm[e];return!!n&&!n.includes(t)}case we.VotingReputation:{let n=$l[e];return!!n&&!n.includes(t)}case we.Whitelist:{let n=fm[e];return!!n&&!n.includes(t)}default:return Nc(a,"Could not find extension with name")}};var Zx={[we.CoinMachine]:Vc,[we.EvaluatedExpenditure]:qc,[we.FundingQueue]:Wc,[we.IVotingReputation]:Ql,[we.OneTxPayment]:$c,[we.ReputationBootstrapper]:Yc,[we.StagedExpenditure]:im,[we.StakedExpenditure]:tm,[we.StreamingPayments]:om,[we.TokenSupplier]:lm,[we.VotingReputation]:Ql,[we.Whitelist]:cm};var Bh=kn(mm(),1);var bp=kn(Nh(),1);var Re;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Re||(Re={}));var xp=2,hp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(hp||(hp={}));var Dh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,y1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),gp=(a,e)=>{let t=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=bp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==xp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Dh(t.errors);throw new Error(n)};var Oh=(a,e)=>{let t=a===Re.Colony?y1(e):e,n=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=bp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:xp});if(!n.success){let i=Dh(n.errors);throw new Error(i)}return n.data};var Tp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},vp=Tp;var wp=(0,Bh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Hs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Br=class{adapter;constructor(e){this.adapter=e||new vp}static eventSupportsMetadata(e){return!!Object.keys(Hs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await wp(n)).json();return gp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await wp(n)).json(),s=Object.entries(Hs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return gp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await wp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Oh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var f1=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0,_p=class{token;PINATA_GATEWAY_ENDPOINT="https://gateway.pinata.cloud/ipfs";name="PINATA";constructor(e){let t=e||f1;if(!t)throw new Error('Cannot find pinata token. Please supply it as an argument to the class or as "process.env.COLONY_IPFS_PINATA_TOKEN (in NodeJS)"');this.token=t}getIpfsUrl(e){return`${this.PINATA_GATEWAY_ENDPOINT}/${e}`}async uploadJson(e){return(await(await fetch("https://api.pinata.cloud/pinning/pinJSONToIPFS",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:`Bearer ${this.token}`},body:JSON.stringify({pinataContent:JSON.parse(e)})})).json()).IpfsHash}},kp=_p;var Ap=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};xe(Tn,"abi",Ap);var Ep=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};xe(vn,"abi",Ep);var Mp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ci=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};xe(Ci,"abi",Mp);var Wu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Fh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",B1=a=>a.length>1,On=class extends hi{constructor(...e){B1(e)?super(...e):super(Wu,Fh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Wu)}static connect(e,t){return new oe(e,Wu,t)}};xe(On,"bytecode",Fh),xe(On,"abi",Wu);var Ip=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Si=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};xe(Si,"abi",Ip);var Cp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};xe(Ri,"abi",Cp);var Pi;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Pi||(Pi={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Lh}=ht;async function U1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var V1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=On.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await U1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Lh)}catch{i=!1}try{await t.nonces(Lh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Si.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Pi.TokenClient,t},Sp=V1;var j1=(a,e)=>{let t=Ri.connect(a,e);return t.clientType=Pi.TokenLockingClient,t},Rp=j1;var{AddressZero:Pp}=ht,H1=Tn.connect(Pp,new ta.BaseProvider(3656691)).interface,q1=Ci.connect(Pp,new ta.BaseProvider(3656691)).interface,G1=vn.connect(Pp,new ta.BaseProvider(3656691)).interface;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],qs=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};qs.abi=Np;var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Gs=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Gs.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Ni.abi=Op;var va=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Hs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Kl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:W1,solidityKeccak256:K1,splitSignature:J1}=te,Di=class extends va{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Dn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=K1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=W1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=J1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Ku=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Bp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Oi.abi=Bp;var Fp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Bi.abi=Fp;var Lp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};Fi.abi=Lp;var Up=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Li.abi=Up;var Vp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};Ui.abi=Vp;var jp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};Vi.abi=jp;var{AddressZero:tg}=ht,Bn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Fa(Bn.extensionType),e.address);if(t===tg)throw new Error(`${Bn.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!La(Bn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Bn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Bn(e,r,n)}static getLatestSupportedVersion(){return Bn.supportedVersions[Bn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Fa(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},ja=Bn;ja.supportedVersions=[{version:3,factory:Li},{version:4,factory:Ui},{version:5,factory:Vi}],ja.extensionType=we.OneTxPayment;var Fn=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var zs=class extends Fn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=On.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var Ws=class extends Fn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Uh=async(a,e)=>{let t=await Sp(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new zs(a,t);case wn.Erc20:return new Fn(a,t);case wn.Erc2612:return new Ws(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Hp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};ji.abi=Hp;var qp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};Hi.abi=qp;var Gp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],qi=class{static createInterface(){return new te.Interface(Gp)}static connect(e,t){return new oe(e,Gp,t)}};qi.abi=Gp;var{AddressZero:zp}=ht;var Ju=F.from(10).pow(18),Ln=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Fa(Ln.extensionType),e.address);if(t===zp)throw new Error(`${Ln.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!La(Ln.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Ln.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Ln.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Ln.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Ln(e,r,n)}static getLatestSupportedVersion(){return Ln.supportedVersions[Ln.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Ds(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,zp,Hl);return[e,t,zp,Hl,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Ku("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ns(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await _i(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Fa(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ha=Ln;Ha.supportedVersions=[{version:7,factory:ji},{version:8,factory:Hi},{version:9,factory:qi}],Ha.extensionType=we.VotingReputation;var rg={["motion"]:Ha,["oneTx"]:ja},Lr=class{static async connect(e,t){let n=await Rr(t,e.signerOrProvider),i=Lr.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Uh(e,s),l=new Lr(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Lr.supportedVersions[Lr.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new aa(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ha.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Fn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await na(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await _i(x,this.colony,r,s),_=await _i(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=rg[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!La(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Fa(i),t.getLatestSupportedVersion()],async s=>({...Ku("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return yu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Wl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Wl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Ur=Lr;Ur.supportedVersions=[{version:11,factory:Oi},{version:12,factory:Bi},{version:13,factory:Fi}];var{splitSignature:sg}=te,$u=class extends va{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Dn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=sg(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Ks=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Rp(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Vh}=te,{AddressZero:Wp}=ht,Js=class{constructor(e,t){this.network=t?.network||Dn.Gnosis,this.ipfs=new Br(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||lu[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Sr[this.network]},this.networkContract=Ni.connect(t?.customNetworkAddress||du[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Ks(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new va({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Di({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new $u({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Wp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Ur.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Rs[this.network],""):null}async getColonyAddress(e){let t=Vh(`${e}${Rs[this.network]}`),n=await this.networkContract.addr(t);return n!==Wp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Ps[this.network],""):null}async getUserAddress(e){let t=Vh(`${e}${Ps[this.network]}`),n=await this.networkContract.addr(t);return n!==Wp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{isAddress:og}=te,jh=new ta.Web3Provider(window.ethereum),Gi,qa={},ug=async(a,e)=>new Js(e,{ipfsAdapter:new kp("INVALID")}).getColony(a),dg=async()=>{let a=await Gi.getBalance();return Ns(a)},lg=async()=>{let a="QmTwksWE2Zn4icTvk5E7QZb1vucGNuu5GUCFZ361r8gKXM",[{domainId:e,fundingPotId:t},,n]=await Gi.createTeam(a).tx().mined();if(!e||!t||!n)throw new Error("Transaction event data not found");let i=await n();if(!i)throw new Error("No metadata found");console.info(i);let[{domainId:r}]=await Gi.deprecateTeam(e,!0).tx().mined();console.info(`${r} successfully deprecated`);let{data:{domainName:s,domainColor:o,domainPurpose:l}}=i;return{domainId:e,fundingPotId:t,domainName:s,domainColor:o,domainPurpose:l}},pg=async()=>{if(!qa.domainId)throw new Error("No domain created yet");let[,a]=await Gi.moveFundsToTeam(pu`0.66`,qa.domainId).tx().mined();return a},yg=async a=>{if(!Gi.ext.oneTx)throw new Error("OneTxPayment extension not installed");let[,e]=await Gi.ext.oneTx.pay(a,pu`0.42`,qa.domainId).tx().mined();return e},fg=async()=>(await jh.send("eth_requestAccounts",[]),jh.getSigner()),Qu=document.querySelector("#address"),Hh=document.querySelector("#button_connect"),qh=document.querySelector("#button_team"),Gh=document.querySelector("#button_fund"),zh=document.querySelector("#recipient"),Wh=document.querySelector("#button_pay"),Kp=document.querySelector("#error"),Kh=document.querySelector("#result");if(!Qu||!zh||!Kp||!Kh||!Hh||!qh||!Gh||!Wh)throw new Error("Could not find all required HTML elements");var Vr=a=>{Kp.innerText=`Found an error: ${a.message}`,console.error(a)},cg=()=>{Kp.innerText=""},_n=a=>{Kh.innerText=a};Hh.addEventListener("click",async()=>{cg();let a=Qu.value;if(!og(a))return Vr(new Error("This is not a valid address"));_n("Processing...");let e=await fg();try{let t=await ug(Qu.value,e);Gi=t;let n=await dg(),i=await t.token.symbol();_n(` +`)}`,y1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),gp=(a,e)=>{let t=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=bp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==xp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Dh(t.errors);throw new Error(n)};var Oh=(a,e)=>{let t=a===Re.Colony?y1(e):e,n=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=bp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:xp});if(!n.success){let i=Dh(n.errors);throw new Error(i)}return n.data};var Tp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},vp=Tp;var wp=(0,Bh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Hs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Br=class{adapter;constructor(e){this.adapter=e||new vp}static eventSupportsMetadata(e){return!!Object.keys(Hs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await wp(n)).json();return gp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await wp(n)).json(),s=Object.entries(Hs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return gp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await wp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Oh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var f1=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0,_p=class{token;PINATA_GATEWAY_ENDPOINT="https://gateway.pinata.cloud/ipfs";name="PINATA";constructor(e){let t=e||f1;if(!t)throw new Error('Cannot find pinata token. Please supply it as an argument to the class or as "process.env.COLONY_IPFS_PINATA_TOKEN (in NodeJS)"');this.token=t}getIpfsUrl(e){return`${this.PINATA_GATEWAY_ENDPOINT}/${e}`}async uploadJson(e){return(await(await fetch("https://api.pinata.cloud/pinning/pinJSONToIPFS",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:`Bearer ${this.token}`},body:JSON.stringify({pinataContent:JSON.parse(e)})})).json()).IpfsHash}},kp=_p;var Ap=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};xe(Tn,"abi",Ap);var Ep=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};xe(vn,"abi",Ep);var Mp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ci=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};xe(Ci,"abi",Mp);var Wu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Fh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",B1=a=>a.length>1,On=class extends hi{constructor(...e){B1(e)?super(...e):super(Wu,Fh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Wu)}static connect(e,t){return new oe(e,Wu,t)}};xe(On,"bytecode",Fh),xe(On,"abi",Wu);var Ip=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Si=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};xe(Si,"abi",Ip);var Cp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};xe(Ri,"abi",Cp);var Pi;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Pi||(Pi={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Lh}=ht;async function U1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var V1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=On.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await U1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Lh)}catch{i=!1}try{await t.nonces(Lh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Si.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Pi.TokenClient,t},Sp=V1;var j1=(a,e)=>{let t=Ri.connect(a,e);return t.clientType=Pi.TokenLockingClient,t},Rp=j1;var{AddressZero:Pp}=ht,H1=Tn.connect(Pp,new ta.BaseProvider(3656691)).interface,q1=Ci.connect(Pp,new ta.BaseProvider(3656691)).interface,G1=vn.connect(Pp,new ta.BaseProvider(3656691)).interface;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],qs=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};qs.abi=Np;var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Gs=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Gs.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Ni.abi=Op;var va=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Hs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Kl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:W1,solidityKeccak256:K1,splitSignature:J1}=te,Di=class extends va{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Dn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=K1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=W1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=J1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Ku=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Bp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Oi.abi=Bp;var Fp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Bi.abi=Fp;var Lp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};Fi.abi=Lp;var Up=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Li.abi=Up;var Vp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};Ui.abi=Vp;var jp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};Vi.abi=jp;var{AddressZero:tg}=ht,Bn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Fa(Bn.extensionType),e.address);if(t===tg)throw new Error(`${Bn.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!La(Bn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Bn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Bn(e,r,n)}static getLatestSupportedVersion(){return Bn.supportedVersions[Bn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Fa(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},ja=Bn;ja.supportedVersions=[{version:3,factory:Li},{version:4,factory:Ui},{version:5,factory:Vi}],ja.extensionType=we.OneTxPayment;var Fn=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var zs=class extends Fn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=On.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var Ws=class extends Fn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Uh=async(a,e)=>{let t=await Sp(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new zs(a,t);case wn.Erc20:return new Fn(a,t);case wn.Erc2612:return new Ws(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Hp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};ji.abi=Hp;var qp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};Hi.abi=qp;var Gp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],qi=class{static createInterface(){return new te.Interface(Gp)}static connect(e,t){return new oe(e,Gp,t)}};qi.abi=Gp;var{AddressZero:zp}=ht;var Ju=F.from(10).pow(18),Ln=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Fa(Ln.extensionType),e.address);if(t===zp)throw new Error(`${Ln.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!La(Ln.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Ln.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Ln.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Ln.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Ln(e,r,n)}static getLatestSupportedVersion(){return Ln.supportedVersions[Ln.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Ds(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,zp,Hl);return[e,t,zp,Hl,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Ku("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ns(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await _i(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Fa(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ha=Ln;Ha.supportedVersions=[{version:7,factory:ji},{version:8,factory:Hi},{version:9,factory:qi}],Ha.extensionType=we.VotingReputation;var rg={["motion"]:Ha,["oneTx"]:ja},Lr=class{static async connect(e,t){let n=await Rr(t,e.signerOrProvider),i=Lr.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Uh(e,s),l=new Lr(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Lr.supportedVersions[Lr.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new aa(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ha.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Fn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await na(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await _i(x,this.colony,r,s),_=await _i(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=rg[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!La(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Fa(i),t.getLatestSupportedVersion()],async s=>({...Ku("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return yu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Wl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Wl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Ur=Lr;Ur.supportedVersions=[{version:11,factory:Oi},{version:12,factory:Bi},{version:13,factory:Fi}];var{splitSignature:sg}=te,$u=class extends va{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Dn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=sg(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Ks=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Rp(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Vh}=te,{AddressZero:Wp}=ht,Js=class{constructor(e,t){this.network=t?.network||Dn.Gnosis,this.ipfs=new Br(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||lu[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Sr[this.network]},this.networkContract=Ni.connect(t?.customNetworkAddress||du[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Ks(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new va({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Di({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new $u({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Wp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Ur.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Rs[this.network],""):null}async getColonyAddress(e){let t=Vh(`${e}${Rs[this.network]}`),n=await this.networkContract.addr(t);return n!==Wp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Ps[this.network],""):null}async getUserAddress(e){let t=Vh(`${e}${Ps[this.network]}`),n=await this.networkContract.addr(t);return n!==Wp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{isAddress:og}=te,jh=new ta.Web3Provider(window.ethereum),Gi,qa={},ug=async(a,e)=>new Js(e,{ipfsAdapter:new kp("INVALID")}).getColony(a),dg=async()=>{let a=await Gi.getBalance();return Ns(a)},lg=async()=>{let a="QmTwksWE2Zn4icTvk5E7QZb1vucGNuu5GUCFZ361r8gKXM",[{domainId:e,fundingPotId:t},,n]=await Gi.createTeam(a).tx().mined();if(!e||!t||!n)throw new Error("Transaction event data not found");let i=await n();if(!i)throw new Error("No metadata found");console.info(i);let[{domainId:r}]=await Gi.deprecateTeam(e,!0).tx().mined();console.info(`${r} successfully deprecated`);let{data:{domainName:s,domainColor:o,domainPurpose:l}}=i;return{domainId:e,fundingPotId:t,domainName:s,domainColor:o,domainPurpose:l}},pg=async()=>{if(!qa.domainId)throw new Error("No domain created yet");let[,a]=await Gi.moveFundsToTeam(pu`0.66`,qa.domainId).tx().mined();return a},yg=async a=>{if(!Gi.ext.oneTx)throw new Error("OneTxPayment extension not installed");let[,e]=await Gi.ext.oneTx.pay(a,pu`0.42`,qa.domainId).tx().mined();return e},fg=async()=>(await jh.send("eth_requestAccounts",[]),jh.getSigner()),Qu=document.querySelector("#address"),Hh=document.querySelector("#button_connect"),qh=document.querySelector("#button_team"),Gh=document.querySelector("#button_fund"),zh=document.querySelector("#recipient"),Wh=document.querySelector("#button_pay"),Kp=document.querySelector("#error"),Kh=document.querySelector("#result");if(!Qu||!zh||!Kp||!Kh||!Hh||!qh||!Gh||!Wh)throw new Error("Could not find all required HTML elements");var Vr=a=>{Kp.innerText=`Found an error: ${a.message}`,console.error(a)},cg=()=>{Kp.innerText=""},_n=a=>{Kh.innerText=a};Hh.addEventListener("click",async()=>{cg();let a=Qu.value;if(!og(a))return Vr(new Error("This is not a valid address"));_n("Processing...");let e=await fg();try{let t=await ug(Qu.value,e);Gi=t;let n=await dg(),i=await t.token.symbol();_n(` Connected to Colony with address: ${a}. Colony version: ${t.version}. Native token funding: ${n} ${i} diff --git a/basic.js b/basic.js index 4418a12ed..6c19a1a47 100644 --- a/basic.js +++ b/basic.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),B5)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var F5="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ns=null;function lf(a){if(ns==null&&(ns=F5.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),hn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ns=null,new Error("BIP39 Wordlist for en (English) FAILED")}var nl=class extends hn{constructor(){super("en")}getWord(e){return lf(this),ns[e]}getWordIndex(e){return lf(this),ns.indexOf(e)}},al=new nl;hn.register(al);var hi={en:al};var pf="hdnode/5.7.0";var as=new M(pf),L5=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),U5=ve("Bitcoin seed"),cr=2147483648;function ff(a){return(1<=256)throw new Error("Depth too large!");return yf(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,me(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new It(fr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~cr));let n=new Uint8Array(37);if(e&cr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(fa(Qn.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=Bo(F.from(r).add(this.privateKey).mod(L5)):l=new cn(W(r))._addPoint(this.publicKey);let p=t,f=this.mnemonic;return f&&(p=Object.freeze({phrase:f.phrase,path:t,locale:f.locale||"en"})),new It(fr,o,l,this.fingerprint,Bo(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=cr)throw new Error("invalid path index - "+r);n=n._derive(cr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=cr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(fa(Qn.sha512,U5,n));return new It(fr,Bo(i.slice(0,32)),null,"0x00000000",Bo(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=il(n),e=xi(mr(e,n),n),It._fromSeed(rl(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return It._fromSeed(e,null)}static fromExtendedKey(e){let t=ya.decode(e);(t.length!==82||yf(t.slice(0,78))!==e)&&as.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new It(fr,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new It(fr,W(o.slice(1)),null,i,s,r,n,null)}return as.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function rl(a,e){e||(e="");let t=ve("mnemonic"+e,Gt.NFKD);return mi(ve(a,Gt.NFKD),t,2048,64,"sha512")}function mr(a,e){e=il(e),as.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=ff(s);if((j(Xt(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function xi(a,e){if(e=il(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&V5(8-n)),n+=3);let i=a.length/4,r=j(Xt(a))[0]&ff(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function cf(a,e){try{return mr(a,e),!0}catch{}return!1}function mf(a){return(typeof a!="number"||a<0||a>=cr||a%1)&&as.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var hf="random/5.7.0";var sl=new M(hf);function j5(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var xf=j5(),Fo=xf.crypto||xf.msCrypto;(!Fo||!Fo.getRandomValues)&&(sl.warn("WARNING: Missing strong random number source"),Fo={getRandomValues:function(a){return sl.throwError("no secure random source avaialble",M.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Xn(a){(a<=0||a>1024||a%1||a!=a)&&sl.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Fo.getRandomValues(e),j(e)}function is(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var dl=_n(ul());var Lo="json-wallets/5.7.0";function ma(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function hr(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),E=new ha.default.Counter(x),J=new ha.default.ModeOfOperation.ctr(O,E),$=j(J.encrypt(i)),de=fe(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:gf(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(f).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=Xn(16),N=new ha.default.Counter(R),q=new ha.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+hr(I.getUTCMonth()+1,2)+"-"+hr(I.getUTCDate(),2)+"T"+hr(I.getUTCHours(),2)+"-"+hr(I.getUTCMinutes(),2)+"-"+hr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function If(a,e,t){if(Uo(a)){t&&t(0);let n=pl(a,e);return t&&t(1),Promise.resolve(n)}return Vo(a)?Ef(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function Cf(a,e){if(Uo(a))return pl(a,e);if(Vo(a))return Mf(a,e);throw new Error("invalid JSON wallet")}var Sf="wallet/5.7.0";var Rf=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},xr=new M(Sf);function W5(a){return a!=null&&ie(a.privateKey,32)&&a.address!=null}function K5(a){let e=a.mnemonic;return e&&e.phrase}var Cn=class extends St{constructor(e,t){if(super(),W5(e)){let n=new cn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",mn(this.publicKey)),this.address!==ce(e.address)&&xr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),K5(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||ca,locale:i.locale||"en"}));let r=this.mnemonic,s=It.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);mn(s.privateKey)!==this.address&&xr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(cn.isSigningKey(e))e.curve!=="secp256k1"&&xr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new cn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",mn(this.publicKey))}t&&!$t.isProvider(t)&&xr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Cn(this,e)}signTransaction(e){return Ce(e).then(t=>{t.from!=null&&(ce(t.from)!==this.address&&xr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(fe(Zr(t)));return Zr(t,n)})}signMessage(e){return Rf(this,void 0,void 0,function*(){return Fr(this._signingKey().signDigest(er(e)))})}_signTypedData(e,t,n){return Rf(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,r=>(this.provider==null&&xr.throwError("cannot resolve ENS names without a provider",M.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return Fr(this._signingKey().signDigest(bt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),hl(this,e,t,n)}static createRandom(e){let t=Xn(16);e||(e={}),e.extraEntropy&&(t=j(Ie(fe(ye([t,e.extraEntropy])),0,16)));let n=xi(t,e.locale);return Cn.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return If(e,t,n).then(i=>new Cn(i))}static fromEncryptedJsonSync(e,t){return new Cn(Cf(e,t))}static fromMnemonic(e,t,n){return t||(t=ca),new Cn(It.fromMnemonic(e,null,n).derivePath(t))}};function Pf(a,e){return yi(er(a),e)}function Nf(a,e,t,n){return yi(bt.hash(a,e,t),n)}var ea={};Hi(ea,{AlchemyProvider:()=>_r,AlchemyWebSocketProvider:()=>hs,AnkrProvider:()=>xs,BaseProvider:()=>Zn,CloudflareProvider:()=>bs,EtherscanProvider:()=>gs,FallbackProvider:()=>vs,Formatter:()=>Y,InfuraProvider:()=>Ar,InfuraWebSocketProvider:()=>_s,IpcProvider:()=>Cl,JsonRpcBatchProvider:()=>nu,JsonRpcProvider:()=>Yt,JsonRpcSigner:()=>vr,NodesmithProvider:()=>ks,PocketProvider:()=>As,Provider:()=>$t,Resolver:()=>Tr,StaticJsonRpcProvider:()=>ms,UrlJsonRpcProvider:()=>Ct,Web3Provider:()=>Ms,WebSocketProvider:()=>ga,getDefaultProvider:()=>au,getNetwork:()=>ss,isCommunityResourcable:()=>gl,isCommunityResource:()=>ds,showThrottleMessage:()=>Yn});var Df="networks/5.7.1";var Of=new M(Df);function J5(a){return a&&typeof a.renetwork=="function"}function xa(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return xa(t)},e}function qo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return qo(a,n)},t}var Bf={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:xa("homestead")},Ff={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:xa("ropsten")},Lf={chainId:63,name:"classicMordor",_defaultProvider:qo("https://www.ethercluster.com/mordor","classicMordor")},Ho={unspecified:{chainId:0,name:"unspecified"},homestead:Bf,mainnet:Bf,morden:{chainId:2,name:"morden"},ropsten:Ff,testnet:Ff,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:xa("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:xa("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:xa("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:xa("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:qo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Lf,classicTestnet:Lf,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:qo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:xa("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:xa("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ss(a){if(a==null)return null;if(typeof a=="number"){for(let n in Ho){let i=Ho[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=Ho[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=Ho[a.name];if(!e)return typeof a.chainId!="number"&&Of.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&Of.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(J5(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Uf="web/5.7.1";var $5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Vf(a,e){return $5(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var Q5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Sn=new M(Uf);function jf(a){return new Promise(e=>{setTimeout(e,a)})}function Da(a,e){if(a==null)return null;if(typeof a=="string")return a;if(aa(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Jt(a)}catch{}return W(a)}return a}function X5(a){return ve(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function xl(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Sn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Sn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},f=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Sn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(f=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Sn.throwError("basic authentication requires a secure https url",M.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+Zi(ve(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?Yi(_[3]):X5(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Sn.throwError("processing response error",M.errors.SERVER_ERROR,{body:Da(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(E,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Sn.makeError("timeout",M.errors.TIMEOUT,{requestBody:Da(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return Q5(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Sn.throwError("bad response",M.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Da(H,U.headers?U.headers["content-type"]:null),requestBody:Da(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let E=yield t(H,U);return S.cancel(),E}catch(E){if(E.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Jt(r))}catch(l){Sn.throwError("invalid JSON",M.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=ve(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return xl(a,i,n)}function Pn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(f){if(f!==void 0)s()&&t(f);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(f){s()&&n(f)})}p()})}var _l=_n(zf());var Ae="providers/5.7.2";var us=new M(Ae),Y=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),f=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:Y.allowNull(this.accessList.bind(this),null),blockHash:Y.allowNull(s,null),blockNumber:Y.allowNull(l,null),transactionIndex:Y.allowNull(l,null),confirmations:Y.allowNull(l,null),from:t,gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),gasLimit:n,to:Y.allowNull(t,null),value:n,nonce:l,data:r,r:Y.allowNull(this.uint256),s:Y.allowNull(this.uint256),v:Y.allowNull(l),creates:Y.allowNull(t,null),raw:Y.allowNull(r)},e.transactionRequest={from:Y.allowNull(t),nonce:Y.allowNull(l),gasLimit:Y.allowNull(n),gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),to:Y.allowNull(t),value:Y.allowNull(n),data:Y.allowNull(f),type:Y.allowNull(l),accessList:Y.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:Y.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:Y.allowNull(this.address,null),from:Y.allowNull(this.address,null),contractAddress:Y.allowNull(t,null),transactionIndex:l,root:Y.allowNull(o),gasUsed:n,logsBloom:Y.allowNull(r),blockHash:s,transactionHash:s,logs:Y.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:Y.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:Y.allowNull(n),status:Y.allowNull(l),type:p},e.block={hash:Y.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:Y.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:Y.allowNull(t),extraData:r,transactions:Y.allowNull(Y.arrayOf(s)),baseFeePerGas:Y.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=Y.allowNull(Y.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:Y.allowNull(i,void 0),toBlock:Y.allowNull(i,void 0),blockHash:Y.allowNull(s,void 0),address:Y.allowNull(t,void 0),topics:Y.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:Y.allowNull(l),blockHash:Y.allowNull(s),transactionIndex:l,removed:Y.allowNull(this.boolean.bind(this)),address:t,data:Y.allowFalsish(r,"0x"),topics:Y.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return sn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():us.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ce(e)}callAddress(e){if(!ie(e,32))return null;let t=ce(Ie(e,12));return t===oo?null:t}contractAddress(e){return ui(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return Ln(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Nt(n)!==32?us.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return me(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=Y.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return Y.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=Y.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ie(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ie(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return So(e)}receiptLog(e){return Y.check(this.formats.receiptLog,e)}receipt(e){let t=Y.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&us.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):us.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&us.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return Y.check(this.formats.filter,e)}filterLog(e){return Y.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function gl(a){return a&&typeof a.isCommunityResource=="function"}function ds(a){return gl(a)&&a.isCommunityResource()}var Wf=!1;function Yn(){Wf||(Wf=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},he=new M(Ae),rx=10;function Kf(a){return a==null?"null":(Nt(a)!==32&&he.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function Jf(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[Kf(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return Kf(e)}).join("&")}function sx(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function gr(a){if(typeof a=="string"){if(a=a.toLowerCase(),Nt(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+Jf(a);if(go.isForkEvent(a))throw he.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+Jf(a.topics||[])}throw new Error("invalid event - "+a)}function ls(){return new Date().getTime()}function $f(a){return new Promise(e=>{setTimeout(e,a)})}var ox=["block","network","pending","poll"],kl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=sx(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||ox.indexOf(this.tag)>=0}},ux={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Tl(a){return me(F.from(a).toHexString(),32)}function Qf(a){return ya.encode(ye([a,Ie(Xt(Xt(a)),0,4)]))}var Zf=new RegExp("^(ipfs)://(.*)$","i"),Xf=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Zf,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Ko(a,e){try{return Jt(ps(a,e))}catch{}return null}function ps(a,e){if(a==="0x")return null;let t=F.from(Ie(a,e,e+32)).toNumber(),n=F.from(Ie(a,t,t+32)).toNumber();return Ie(a,t+32,t+32+n)}function vl(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):he.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function Yf(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function dx(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function ec(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===M.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:kt([e,Ia(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=kt(["0x9061b923",ec([$r(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&he.throwError("resolver threw error",M.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=ps(r,0)),r}catch(r){if(r.code===M.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?ps(n,0):null})}_getAddress(e,t){let n=ux[String(e)];if(n==null&&he.throwError(`unsupported coin type: ${e}`,M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return Qf(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return Qf(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=_l.default.toWords(i.slice(2));return o.unshift(s),_l.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===Qi?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===M.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",Tl(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&he.throwError("invalid or unsupported coin data",M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return he.throwError("invalid or unsupported content hash data",M.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=ve(e);t=ye([Tl(64),Tl(t.length),t]),t.length%32!==0&&(t=ye([t,me("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Jt(n)})}},wl=null,lx=1,Zn=class extends $t{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=mt(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):he.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||he.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Pn(()=>this._ready().then(e=>e,e=>{if(!(e.code===M.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return wl==null&&(wl=new Y),wl}static getNetwork(e){return ss(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Rn({url:p,errorPassThrough:!0},f,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return he.throwError(`response not found during CCIP fetch: ${C}`,M.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return he.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,M.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(ls()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=ls(),n=Ce({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=ls();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=lx++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)he.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",he.makeError("network block skew detected",M.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return he.throwError("provider does not support network detection",M.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield $f(0),this._network;let n=he.makeError("underlying network changed",M.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=ls();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,f=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield $f(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{f()||o(he.makeError("timeout exceeded",M.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Ln(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Nt(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&he.throwError("Transaction hash mismatch from Provider.sendTransaction.",M.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&he.throwError("transaction failed",M.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Ce(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Ce(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=rx&&he.throwError("CCIP read exceeded maximum redirections",M.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Nt(r)%32===4)try{let s=Ie(r,4),o=Ie(s,0,32);F.from(o).eq(i)||he.throwError("CCIP Read sender did not match",M.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ie(s,32,64)).toNumber(),f=F.from(Ie(s,p,p+32)).toNumber(),x=Ie(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Ce({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),Y.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&he.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new Tr(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||he.throwError("network does not support ENS",M.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Ia(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ie(e))throw n}typeof e!="string"&&he.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=Ko(yield this.call({to:n,data:"0x691f3431"+Ia(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new Tr(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o}try{let o=Ko(yield this.call({to:s,data:"0x691f3431"+Ia(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return he.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new kl(gr(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=gr(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=gr(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=gr(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=gr(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=gr(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var ba=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Mt=new M(Ae),px=["call","estimateGas"];function fs(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ie(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=fs(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return fs(JSON.parse(a),e)}catch{}return null}function nc(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=fs(e,!0);if(r)return r.data;Mt.throwError("missing revert data in call exception; Transaction reverted without a reason string",M.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=fs(e.body,!1);r==null&&(r=fs(e,!1)),r&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===M.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Mt.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Mt.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Mt.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Mt.throwError("legacy pre-eip-155 transactions not supported",M.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),px.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function tc(a){return new Promise(function(e){setTimeout(e,a)})}function yx(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function ys(a){return a&&a.toLowerCase()}var Al={},vr=class extends St{constructor(e,t,n){if(super(),e!==Al)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Mt.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Mt.throwError("cannot alter JSON-RPC Signer connection",M.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new Ml(Al,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Mt.throwError("unknown account #"+this._index,M.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>ba(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Mt.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Ce({tx:Ce(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Mt.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected transaction",M.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),nc("sendTransaction",s,r)))})}signTransaction(e){return Mt.throwError("signing transactions is unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return ba(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Pn(()=>ba(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return ba(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return ba(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return ba(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(bt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return ba(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},Ml=class extends vr{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},fx={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},Yt=class extends Zn{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=mt(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return ba(this,void 0,void 0,function*(){yield tc(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=mt(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new vr(Al,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:ct(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Rn(this.connection,JSON.stringify(n),yx).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ys(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ys(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ys(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ys(t.address),me(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=ys(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return ba(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Mt.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return nc(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return tc(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(fx);if(t)for(let r in t)t[r]&&(n[r]=!0);zi(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Ln(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=sn(e.accessList)),i}};var wr=null;try{if(wr=WebSocket,wr==null)throw new Error("inject please")}catch{let e=new M(Ae);wr=function(){e.throwError("WebSockets not supported in this environment",M.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var El=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Jo=new M(Ae),cx=1,ga=class extends Yt{constructor(e,t){t==="any"&&Jo.throwError("WebSocketProvider does not support 'any' network yet",M.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new wr(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){Jo.throwError("cannot reset events block on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){Jo.throwError("cannot set polling interval on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return El(this,void 0,void 0,function*(){return null})}set polling(e){!e||Jo.throwError("cannot set polling on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=cx++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return El(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return El(this,void 0,void 0,function*(){this.websocket.readyState===wr.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var mx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},cs=new M(Ae),ms=class extends Yt{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return mx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||cs.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Ct=class extends ms{constructor(e,t){cs.checkAbstract(new.target,Ct),e=mt(new.target,"getNetwork")(e),t=mt(new.target,"getApiKey")(t);let n=mt(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){cs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return cs.throwError("API provider does not support signing",M.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return cs.throwError("not implemented; sub-classes must override getUrl",M.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var ac=new M(Ae),$o="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",hs=class extends ga{constructor(e,t){let n=new _r(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===$o}},_r=class extends Ct{static getWebSocketProvider(e,t){return new hs(e,t)}static getApiKey(e){return e==null?$o:(e&&typeof e!="string"&&ac.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:ac.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===$o&&Yn(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===$o}};var hx=new M(Ae),Qo="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function xx(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return hx.throwArgumentError("unsupported network","name",a)}var xs=class extends Ct{isCommunityResource(){return this.apiKey===Qo}static getApiKey(e){return e??Qo}static getUrl(e,t){t==null&&(t=Qo);let n={allowGzip:!0,url:"https://"+xx(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===Qo&&Yn(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var bx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},ic=new M(Ae),bs=class extends Ct{static getApiKey(e){return e!=null&&ic.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:ic.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return bx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var Xo=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Oa=new M(Ae);function rc(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Ln(W(n)):t==="accessList"?n="["+sn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function gx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function sc(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function oc(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function Il(a,e,t){if(a==="call"&&e.code===M.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Oa.throwError("missing revert data in call exception",M.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===M.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Oa.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Oa.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Oa.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Oa.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var gs=class extends Zn{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Oa.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return Xo(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?sc:gx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(f,x)=>(this.isCommunityResource()&&Yn(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(f=>`${f}=${r[f]}`).join("&"));let p=yield Rn(o,l,s||sc);return this.emit("debug",{action:"response",request:i,response:ct(p),provider:this}),p})}detectNetwork(){return Xo(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return Xo(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Il("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=rc(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Il("call",r,t.transaction)}}case"estimateGas":{let i=rc(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Il("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=oc(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=oc(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Oa.throwError("unsupported topic count",M.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Oa.throwError("unsupported topic format",M.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var eu=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},bi=new M(Ae);function Yo(){return new Date().getTime()}function uc(a){let e=null;for(let t=0;te?null:(n+i)/2}function kr(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>kr(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=kr(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var Tx=1;function lc(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var vx=[M.errors.CALL_EXCEPTION,M.errors.INSUFFICIENT_FUNDS,M.errors.NONCE_EXPIRED,M.errors.REPLACEMENT_UNDERPRICED,M.errors.UNPREDICTABLE_GAS_LIMIT],wx=["address","args","errorArgs","errorSignature","method","transaction"];function Zo(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function _x(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function kx(a,e,t){let n=kr;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=dc(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return dc(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,kr(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),kr(i))}:n=function(i){return i==null?null:kr(i)};break;default:throw new Error("unknown method: "+e)}return _x(n,a.quorum)}function Ts(a,e){return eu(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Pn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function Ax(a,e,t,n){return eu(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield Ts(a,e)),i.getLogs(r)}}return bi.throwError("unknown method error",M.errors.UNKNOWN_ERROR,{method:t,params:n})})}var vs=class extends Zn{constructor(e,t){e.length===0&&bi.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if($t.isProvider(s)){let f=ds(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:f,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=ds(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&bi.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&bi.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=uc(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return eu(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return uc(e)})}perform(e,t){return eu(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(f=>f.hash,f=>f)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=Yo(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=Ax(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Zo(_,Yo()),request:{method:e,params:ct(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Zo(_,Yo()),request:{method:e,params:ct(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Zo(_,null),request:{method:e,params:ct(t)},provider:this}),p+=_.weight}let f=[];i.forEach(_=>{_.done||!_.runner||(f.push(_.runner),_.staller&&f.push(_.staller.getPromise()))}),f.length&&(yield Promise.race(f));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield lc(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return vx.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};wx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),bi.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),bi.throwError("failed to meet quorum",M.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>Zo(l)),provider:this})})}};var Cl=null;var tu=new M(Ae),ws="84842078b09946638c03157f83405213",_s=class extends ga{constructor(e,t){let n=new Ar(e,t),i=n.connection;i.password&&tu.throwError("INFURA WebSocket project secrets unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===ws}},Ar=class extends Ct{static getWebSocketProvider(e,t){return new _s(e,t)}static getApiKey(e){let t={apiKey:ws,projectId:ws,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(tu.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),tu.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:tu.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===ws&&Yn(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===ws}};var nu=class extends Yt{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:ct(o),provider:this}),Rn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,f)=>{let x=l[f];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Sl=new M(Ae),Mx="ETHERS_JS_SHARED",ks=class extends Ct{static getApiKey(e){return e&&typeof e!="string"&&Sl.throwArgumentError("invalid apiKey","apiKey",e),e||Mx}static getUrl(e,t){Sl.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Sl.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var pc=new M(Ae),yc="62e1ad51b37b8e00394bda3b",As=class extends Ct{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=yc:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:pc.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:pc.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===yc}};var fc=new M(Ae),Ex=1;function cc(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:Ex++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:ct(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let f=new Error(p.error.message);return f.code=p.error.code,f.data=p.error.data,o(f)}s(p.result)})})}}function Ix(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:ct(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var Ms=class extends Yt{constructor(e,t){e==null&&fc.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Ix(e)):e.sendAsync?i=cc(e,e.sendAsync.bind(e)):e.send?i=cc(e,e.send.bind(e)):fc.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var mc=new M(Ae);function au(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new Yt(a);case"ws":case"wss":return new ga(a);default:mc.throwArgumentError("unsupported URL scheme","network",a)}}let t=ss(a);return(!t||!t._defaultProvider)&&mc.throwError("unsupported getDefaultProvider network",M.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:vs,AlchemyProvider:_r,AnkrProvider:xs,CloudflareProvider:bs,EtherscanProvider:gs,InfuraProvider:Ar,JsonRpcProvider:Yt,NodesmithProvider:ks,PocketProvider:As,Web3Provider:Ms,IpcProvider:null},e)}var te={};Hi(te,{AbiCoder:()=>Xi,ConstructorFragment:()=>Dt,ErrorFragment:()=>tn,EventFragment:()=>Ht,FormatTypes:()=>ge,Fragment:()=>qt,FunctionFragment:()=>Ot,HDNode:()=>It,Indexed:()=>oa,Interface:()=>Ca,LogDescription:()=>tr,Logger:()=>M,ParamType:()=>pt,RLP:()=>Zs,SigningKey:()=>cn,SupportedAlgorithm:()=>Qn,TransactionDescription:()=>nr,TransactionTypes:()=>Co,UnicodeNormalizationForm:()=>Gt,Utf8ErrorFuncs:()=>fo,Utf8ErrorReason:()=>Bt,_TypedDataEncoder:()=>bt,_fetchData:()=>xl,_toEscapedUtf8String:()=>wd,accessListify:()=>sn,arrayify:()=>j,base58:()=>ya,base64:()=>Id,checkProperties:()=>zi,checkResultErrors:()=>Ki,commify:()=>_c,computeAddress:()=>mn,computeHmac:()=>fa,computePublicKey:()=>Yr,concat:()=>ye,deepCopy:()=>ct,defaultAbiCoder:()=>Kr,defaultPath:()=>ca,defineReadOnly:()=>B,dnsEncode:()=>$r,entropyToMnemonic:()=>xi,fetchJson:()=>Rn,formatBytes32String:()=>_d,formatEther:()=>kc,formatUnits:()=>Rl,getAccountPath:()=>mf,getAddress:()=>ce,getContractAddress:()=>ui,getCreate2Address:()=>Iy,getIcapAddress:()=>Ey,getJsonWalletAddress:()=>yl,getStatic:()=>mt,hashMessage:()=>er,hexConcat:()=>kt,hexDataLength:()=>Nt,hexDataSlice:()=>Ie,hexStripZeros:()=>pd,hexValue:()=>Ln,hexZeroPad:()=>me,hexlify:()=>W,id:()=>nn,isAddress:()=>My,isBytes:()=>on,isBytesLike:()=>aa,isHexString:()=>ie,isValidMnemonic:()=>cf,isValidName:()=>Sd,joinSignature:()=>Fr,keccak256:()=>fe,mnemonicToEntropy:()=>mr,mnemonicToSeed:()=>rl,namehash:()=>Ia,nameprep:()=>Ed,parseBytes32String:()=>kd,parseEther:()=>Ac,parseTransaction:()=>So,parseUnits:()=>Pl,poll:()=>Pn,randomBytes:()=>Xn,recoverAddress:()=>yi,recoverPublicKey:()=>Io,resolveProperties:()=>Ce,ripemd160:()=>ts,serializeTransaction:()=>Zr,sha256:()=>Xt,sha512:()=>tl,shallowCopy:()=>_e,shuffled:()=>is,solidityKeccak256:()=>bc,solidityPack:()=>iu,soliditySha256:()=>gc,splitSignature:()=>Un,stripZeros:()=>Zt,toUtf8Bytes:()=>ve,toUtf8CodePoints:()=>Ea,toUtf8String:()=>Jt,verifyMessage:()=>Pf,verifyTypedData:()=>Nf,zeroPad:()=>ii});var hc="solidity/5.7.0";var Cx=new RegExp("^bytes([0-9]+)$"),Sx=new RegExp("^(u?int)([0-9]*)$"),Rx=new RegExp("^(.*)\\[([0-9]*)\\]$"),Px="0000000000000000000000000000000000000000000000000000000000000000",Mr=new M(hc);function xc(a,e,t){switch(a){case"address":return t?ii(e,32):j(e);case"string":return ve(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?ii(e,32):j(e)}let n=a.match(Sx);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Mr.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),ii(e,i/8)}if(n=a.match(Cx),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Mr.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Mr.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+Px).substring(0,66)):e}if(n=a.match(Rx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Mr.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(xc(i,o,!0))}),ye(s)}return Mr.throwArgumentError("invalid type","type",a)}function iu(a,e){a.length!=e.length&&Mr.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(xc(n,e[i]))}),W(ye(t))}function bc(a,e){return fe(iu(a,e))}function gc(a,e){return Xt(iu(a,e))}var Tc="units/5.7.0";var vc=new M(Tc),wc=["wei","kwei","mwei","gwei","szabo","finney","ether"];function _c(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&vc.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Rl(a,e){if(typeof e=="string"){let t=wc.indexOf(e);t!==-1&&(e=3*t)}return Gi(a,e??18)}function Pl(a,e){if(typeof a!="string"&&vc.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=wc.indexOf(e);t!==-1&&(e=3*t)}return dn(a,e??18)}function kc(a){return Rl(a,18)}function Ac(a){return Pl(a,18)}var ru="ethers/5.7.2";var Mc=new M(ru);try{let a=window;a._ethers==null&&(a._ethers=Nl)}catch{}var Nn;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(Nn||(Nn={}));var su;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(su||(su={}));var Er;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Er||(Er={}));var ou;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(ou||(ou={}));var Es;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Es||(Es={}));var Is;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Is||(Is={}));var Cs;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Cs||(Cs={}));var Ss;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(Ss||(Ss={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var zt;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(zt||(zt={}));var Ol="0x12345678",Dl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(Dl||(Dl={}));var vt;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(vt||(vt={}));var we;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(we||(we={}));var Bl=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],gi=class{static createInterface(){return new te.Interface(Bl)}static connect(e,t){return new oe(e,Bl,t)}};xe(gi,"abi",Bl);var Fl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],Ti=class{static createInterface(){return new te.Interface(Fl)}static connect(e,t){return new oe(e,Fl,t)}};xe(Ti,"abi",Fl);var Ec=(a,e)=>{throw new Error(`${e}: ${a}`)},Ll=a=>a!=null;var{keccak256:Dx,toUtf8Bytes:Ox}=te,{MaxUint256:Bx}=ht;var Ul=a=>te.formatEther(a);var Vl=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(vt.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(Ll)},vi=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return Bx;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},Ba=a=>Dx(Ox(a));var Ir=async(a,e)=>(await Ti.connect(a,e).version()).toNumber(),jl=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(Ll);var{hexDataSlice:Hl}=te,{MaxUint256:Fx}=ht,Ic=a=>{let e=Hl(a,0,3),t=F.from(Hl(a,4,35)),n=F.from(Hl(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Cc=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),Fx,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await vi(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},Lx=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Cc(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?ta(a,e,t,n[0],i):Lx(a,e,t,n,i):Cc(a,e,t,n,i);var{MaxUint256:Sc}=ht,{AddressZero:Ux}=ht;async function Vx(a,e){let t;try{return t=await a.getCapabilityRoles(te.hexZeroPad(e,4)),uu(t)}catch{return[]}}async function Rs(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:f,childSkillIndex:x}=Ic(s),C=gi.connect(r,n.signer||n.provider),_=await Vx(C,p);if(_.includes(vt.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Sc}else{let{skillId:U}=await e.getDomain(f),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Sc;else{let{children:E}=await a.getSkill(l),J=E.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,Ux);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:jx}=ht,na=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||Nn.Gnosis;this.endpointUrl=n?.customEndpointUrl||Er[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await na.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await na.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await na.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let f=p+1,x=await this.colony.getDomain(f);return{domainId:f,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,f=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return f&&(p=f?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return na.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${jx}/noProof`,s=await na.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var _t=a=>Array.from(Array(a-1)).map(e=>e+1);var Rc=10,Nk=_t(Rc),Pc={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},Nc=Rc-1;var Dc=6,Bk=_t(Dc),Oc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},Bc=Dc-1;var Fc=7,Uk=_t(Fc),Lc={1:[],2:[],3:[],4:[],5:[],6:[]},Uc=Fc-1;var Vc=7,Hk=_t(Vc),jc={1:[],2:[],3:[],4:[],5:[],6:[]},Hc=Vc-1;var qc=4,zk=_t(qc),Gc={1:[],2:[],3:[]},zc=qc-1;var Wc=5,Jk=_t(Wc),Kc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},Jc=Wc-1;var $c=2,Xk=_t($c),Qc={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},Xc=$c-1;var Yc=4,eA=_t(Yc),Zc={1:[1,2,3],2:[1,2,3],3:[1,2,3]},em=Yc-1;var tm=7,aA=_t(tm),nm={1:[],2:[],3:[],4:[],5:[],6:[]},am=tm-1;var im=11,sA=_t(im),ql={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Gl=im-1;var rm=6,dA=_t(rm),sm={1:[],2:[],3:[],4:[],5:[]},om=rm-1;var Fa=(a,e,t)=>{switch(a){case we.CoinMachine:{let n=Pc[e];return!!n&&!n.includes(t)}case we.EvaluatedExpenditure:{let n=Oc[e];return!!n&&!n.includes(t)}case we.FundingQueue:{let n=Lc[e];return!!n&&!n.includes(t)}case we.IVotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.OneTxPayment:{let n=jc[e];return!!n&&!n.includes(t)}case we.ReputationBootstrapper:{let n=Gc[e];return!!n&&!n.includes(t)}case we.StagedExpenditure:{let n=Qc[e];return!!n&&!n.includes(t)}case we.StakedExpenditure:{let n=Kc[e];return!!n&&!n.includes(t)}case we.StreamingPayments:{let n=Zc[e];return!!n&&!n.includes(t)}case we.TokenSupplier:{let n=nm[e];return!!n&&!n.includes(t)}case we.VotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.Whitelist:{let n=sm[e];return!!n&&!n.includes(t)}default:return Ec(a,"Could not find extension with name")}};var Hx={[we.CoinMachine]:Nc,[we.EvaluatedExpenditure]:Bc,[we.FundingQueue]:Uc,[we.IVotingReputation]:Gl,[we.OneTxPayment]:Hc,[we.ReputationBootstrapper]:zc,[we.StagedExpenditure]:Xc,[we.StakedExpenditure]:Jc,[we.StreamingPayments]:em,[we.TokenSupplier]:am,[we.VotingReputation]:Gl,[we.Whitelist]:om};var Ch=_n(um(),1);var yp=_n(Mh(),1);var Re;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Re||(Re={}));var pp=2,lp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(lp||(lp={}));var Eh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,t1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Eh(t.errors);throw new Error(n)};var Ih=(a,e)=>{let t=a===Re.Colony?t1(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:pp});if(!n.success){let i=Eh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ch.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Us={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Nr=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Us).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Us).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Ih(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var BM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new te.Interface(xp)}static connect(e,t){return new oe(e,xp,t)}};xe(Tn,"abi",xp);var bp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new te.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(vn,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ei=class{static createInterface(){return new te.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Ei,"abi",gp);var Hu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Sh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",k1=a=>a.length>1,Dn=class extends ci{constructor(...e){k1(e)?super(...e):super(Hu,Sh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Hu)}static connect(e,t){return new oe(e,Hu,t)}};xe(Dn,"bytecode",Sh),xe(Dn,"abi",Hu);var Tp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new te.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(Ii,"abi",Tp);var vp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ci=class{static createInterface(){return new te.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Si;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Si||(Si={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Rh}=ht;async function E1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var I1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await E1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Rh)}catch{i=!1}try{await t.nonces(Rh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Ii.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Si.TokenClient,t},wp=I1;var C1=(a,e)=>{let t=Ci.connect(a,e);return t.clientType=Si.TokenLockingClient,t},_p=C1;var{AddressZero:kp}=ht,S1=Tn.connect(kp,new ea.BaseProvider(3656691)).interface,R1=Ei.connect(kp,new ea.BaseProvider(3656691)).interface,P1=vn.connect(kp,new ea.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Vs=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Vs.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],js=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};js.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Ri.abi=Ep;var Ta=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Us[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:D1,solidityKeccak256:O1,splitSignature:B1}=te,Pi=class extends Ta{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=O1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=D1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=B1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},qu=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Ni.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Di.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Oi.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Bi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Fi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Li.abi=Np;var{AddressZero:q1}=ht,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(On.extensionType),e.address);if(t===q1)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},Va=On;Va.supportedVersions=[{version:3,factory:Bi},{version:4,factory:Fi},{version:5,factory:Li}],Va.extensionType=we.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var Hs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var qs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Ph=async(a,e)=>{let t=await wp(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new Hs(a,t);case wn.Erc20:return new Bn(a,t);case wn.Erc2612:return new qs(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Ui.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Vi.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};ji.abi=Bp;var{AddressZero:Fp}=ht;var Gu=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(Fn.extensionType),e.address);if(t===Fp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Rs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Ol);return[e,t,Fp,Ol,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...qu("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await vi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},ja=Fn;ja.supportedVersions=[{version:7,factory:Ui},{version:8,factory:Vi},{version:9,factory:ji}],ja.extensionType=we.VotingReputation;var K1={["motion"]:ja,["oneTx"]:Va},Or=class{static async connect(e,t){let n=await Ir(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Ph(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new na(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Va.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ta(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await vi(x,this.colony,r,s),_=await vi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=K1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Fa(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Ba(i),t.getLatestSupportedVersion()],async s=>({...qu("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return uu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Br=Or;Br.supportedVersions=[{version:11,factory:Ni},{version:12,factory:Di},{version:13,factory:Oi}];var{splitSignature:J1}=te,zu=class extends Ta{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=J1(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Gs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=_p(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Nh}=te,{AddressZero:Lp}=ht,zs=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Nr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||ou[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Er[this.network]},this.networkContract=Ri.connect(t?.customNetworkAddress||su[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Gs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new Ta({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Pi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new zu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Lp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Br.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Is[this.network],""):null}async getColonyAddress(e){let t=Nh(`${e}${Is[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Cs[this.network],""):null}async getUserAddress(e){let t=Nh(`${e}${Cs[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{formatEther:$1,isAddress:Q1}=te,X1=new ea.JsonRpcProvider(Es.Gnosis),Y1=async a=>{let n=await(await new zs(X1).getColony(a)).getBalance(Ss.Gnosis.CLNY);return $1(n)},Vp=document.querySelector("#address"),Oh=document.querySelector("#button"),jp=document.querySelector("#error"),Bh=document.querySelector("#result");if(!Vp||!Oh||!jp||!Bh)throw new Error("Could not find all required HTML elements");var Dh=a=>{jp.innerText=a},Z1=()=>{jp.innerText=""},Up=a=>{Bh.innerText=a};Oh.addEventListener("click",async()=>{Z1();let a=Vp?.value;if(!Q1(a))return Dh("This is not a valid address");Up("Thinking..."),Vp.value="";let e;try{e=await Y1(a),Up(`${e} CLNY in root domain of Colony with address: ${a}`)}catch(t){Dh(`Found an error: ${t.message}`),Up("")}return null});})(); +`)}`,t1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Eh(t.errors);throw new Error(n)};var Ih=(a,e)=>{let t=a===Re.Colony?t1(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:pp});if(!n.success){let i=Eh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ch.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Us={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Nr=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Us).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Us).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Ih(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var BM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new te.Interface(xp)}static connect(e,t){return new oe(e,xp,t)}};xe(Tn,"abi",xp);var bp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new te.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(vn,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ei=class{static createInterface(){return new te.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Ei,"abi",gp);var Hu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Sh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",k1=a=>a.length>1,Dn=class extends ci{constructor(...e){k1(e)?super(...e):super(Hu,Sh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Hu)}static connect(e,t){return new oe(e,Hu,t)}};xe(Dn,"bytecode",Sh),xe(Dn,"abi",Hu);var Tp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new te.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(Ii,"abi",Tp);var vp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ci=class{static createInterface(){return new te.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Si;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Si||(Si={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Rh}=ht;async function E1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var I1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await E1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Rh)}catch{i=!1}try{await t.nonces(Rh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Ii.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Si.TokenClient,t},wp=I1;var C1=(a,e)=>{let t=Ci.connect(a,e);return t.clientType=Si.TokenLockingClient,t},_p=C1;var{AddressZero:kp}=ht,S1=Tn.connect(kp,new ea.BaseProvider(3656691)).interface,R1=Ei.connect(kp,new ea.BaseProvider(3656691)).interface,P1=vn.connect(kp,new ea.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Vs=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Vs.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],js=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};js.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Ri.abi=Ep;var Ta=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Us[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:D1,solidityKeccak256:O1,splitSignature:B1}=te,Pi=class extends Ta{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=O1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=D1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=B1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},qu=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Ni.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Di.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Oi.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Bi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Fi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Li.abi=Np;var{AddressZero:q1}=ht,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(On.extensionType),e.address);if(t===q1)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},Va=On;Va.supportedVersions=[{version:3,factory:Bi},{version:4,factory:Fi},{version:5,factory:Li}],Va.extensionType=we.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var Hs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var qs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Ph=async(a,e)=>{let t=await wp(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new Hs(a,t);case wn.Erc20:return new Bn(a,t);case wn.Erc2612:return new qs(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Ui.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Vi.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};ji.abi=Bp;var{AddressZero:Fp}=ht;var Gu=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(Fn.extensionType),e.address);if(t===Fp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Rs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Ol);return[e,t,Fp,Ol,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...qu("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await vi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},ja=Fn;ja.supportedVersions=[{version:7,factory:Ui},{version:8,factory:Vi},{version:9,factory:ji}],ja.extensionType=we.VotingReputation;var K1={["motion"]:ja,["oneTx"]:Va},Or=class{static async connect(e,t){let n=await Ir(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Ph(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new na(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Va.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ta(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await vi(x,this.colony,r,s),_=await vi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=K1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Fa(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Ba(i),t.getLatestSupportedVersion()],async s=>({...qu("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return uu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Br=Or;Br.supportedVersions=[{version:11,factory:Ni},{version:12,factory:Di},{version:13,factory:Oi}];var{splitSignature:J1}=te,zu=class extends Ta{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=J1(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Gs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=_p(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Nh}=te,{AddressZero:Lp}=ht,zs=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Nr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||ou[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Er[this.network]},this.networkContract=Ri.connect(t?.customNetworkAddress||su[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Gs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new Ta({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Pi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new zu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Lp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Br.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Is[this.network],""):null}async getColonyAddress(e){let t=Nh(`${e}${Is[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Cs[this.network],""):null}async getUserAddress(e){let t=Nh(`${e}${Cs[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{formatEther:$1,isAddress:Q1}=te,X1=new ea.JsonRpcProvider(Es.Gnosis),Y1=async a=>{let n=await(await new zs(X1).getColony(a)).getBalance(Ss.Gnosis.CLNY);return $1(n)},Vp=document.querySelector("#address"),Oh=document.querySelector("#button"),jp=document.querySelector("#error"),Bh=document.querySelector("#result");if(!Vp||!Oh||!jp||!Bh)throw new Error("Could not find all required HTML elements");var Dh=a=>{jp.innerText=a},Z1=()=>{jp.innerText=""},Up=a=>{Bh.innerText=a};Oh.addEventListener("click",async()=>{Z1();let a=Vp?.value;if(!Q1(a))return Dh("This is not a valid address");Up("Thinking..."),Vp.value="";let e;try{e=await Y1(a),Up(`${e} CLNY in root domain of Colony with address: ${a}`)}catch(t){Dh(`Found an error: ${t.message}`),Up("")}return null});})(); /** * [js-sha3]{@link https://github.com/emn178/js-sha3} * diff --git a/events.js b/events.js index e3a0bd5eb..c577bc99a 100644 --- a/events.js +++ b/events.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),D5)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var O5="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ts=null;function df(a){if(ts==null&&(ts=O5.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),hn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ts=null,new Error("BIP39 Wordlist for en (English) FAILED")}var Qd=class extends hn{constructor(){super("en")}getWord(e){return df(this),ts[e]}getWordIndex(e){return df(this),ts.indexOf(e)}},Xd=new Qd;hn.register(Xd);var xi={en:Xd};var lf="hdnode/5.7.0";var ns=new M(lf),B5=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),F5=ve("Bitcoin seed"),fr=2147483648;function yf(a){return(1<=256)throw new Error("Depth too large!");return pf(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,me(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new It(yr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~fr));let n=new Uint8Array(37);if(e&fr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(ya($n.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=No(F.from(r).add(this.privateKey).mod(B5)):l=new cn(W(r))._addPoint(this.publicKey);let p=t,f=this.mnemonic;return f&&(p=Object.freeze({phrase:f.phrase,path:t,locale:f.locale||"en"})),new It(yr,o,l,this.fingerprint,No(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=fr)throw new Error("invalid path index - "+r);n=n._derive(fr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=fr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(ya($n.sha512,F5,n));return new It(yr,No(i.slice(0,32)),null,"0x00000000",No(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=Yd(n),e=bi(cr(e,n),n),It._fromSeed(Zd(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return It._fromSeed(e,null)}static fromExtendedKey(e){let t=pa.decode(e);(t.length!==82||pf(t.slice(0,78))!==e)&&ns.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new It(yr,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new It(yr,W(o.slice(1)),null,i,s,r,n,null)}return ns.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function Zd(a,e){e||(e="");let t=ve("mnemonic"+e,Gt.NFKD);return hi(ve(a,Gt.NFKD),t,2048,64,"sha512")}function cr(a,e){e=Yd(e),ns.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=yf(s);if((j(Xt(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function bi(a,e){if(e=Yd(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&L5(8-n)),n+=3);let i=a.length/4,r=j(Xt(a))[0]&yf(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function ff(a,e){try{return cr(a,e),!0}catch{}return!1}function cf(a){return(typeof a!="number"||a<0||a>=fr||a%1)&&ns.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var mf="random/5.7.0";var el=new M(mf);function U5(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var hf=U5(),Do=hf.crypto||hf.msCrypto;(!Do||!Do.getRandomValues)&&(el.warn("WARNING: Missing strong random number source"),Do={getRandomValues:function(a){return el.throwError("no secure random source avaialble",M.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Qn(a){(a<=0||a>1024||a%1||a!=a)&&el.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Do.getRandomValues(e),j(e)}function as(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var al=_n(nl());var Oo="json-wallets/5.7.0";function ca(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function mr(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),E=new ma.default.Counter(x),J=new ma.default.ModeOfOperation.ctr(O,E),$=j(J.encrypt(i)),de=fe(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:bf(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(f).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=Qn(16),N=new ma.default.Counter(R),q=new ma.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+mr(I.getUTCMonth()+1,2)+"-"+mr(I.getUTCDate(),2)+"T"+mr(I.getUTCHours(),2)+"-"+mr(I.getUTCMinutes(),2)+"-"+mr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function Ef(a,e,t){if(Bo(a)){t&&t(0);let n=rl(a,e);return t&&t(1),Promise.resolve(n)}return Fo(a)?Mf(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function If(a,e){if(Bo(a))return rl(a,e);if(Fo(a))return Af(a,e);throw new Error("invalid JSON wallet")}var Cf="wallet/5.7.0";var Sf=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},hr=new M(Cf);function G5(a){return a!=null&&ae(a.privateKey,32)&&a.address!=null}function z5(a){let e=a.mnemonic;return e&&e.phrase}var Cn=class extends Bt{constructor(e,t){if(super(),G5(e)){let n=new cn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",mn(this.publicKey)),this.address!==ce(e.address)&&hr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),z5(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||fa,locale:i.locale||"en"}));let r=this.mnemonic,s=It.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);mn(s.privateKey)!==this.address&&hr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(cn.isSigningKey(e))e.curve!=="secp256k1"&&hr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new cn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",mn(this.publicKey))}t&&!$t.isProvider(t)&&hr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Cn(this,e)}signTransaction(e){return Ce(e).then(t=>{t.from!=null&&(ce(t.from)!==this.address&&hr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(fe(Yr(t)));return Yr(t,n)})}signMessage(e){return Sf(this,void 0,void 0,function*(){return Br(this._signingKey().signDigest(Zi(e)))})}_signTypedData(e,t,n){return Sf(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,r=>(this.provider==null&&hr.throwError("cannot resolve ENS names without a provider",M.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return Br(this._signingKey().signDigest(bt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),ll(this,e,t,n)}static createRandom(e){let t=Qn(16);e||(e={}),e.extraEntropy&&(t=j(Ie(fe(ye([t,e.extraEntropy])),0,16)));let n=bi(t,e.locale);return Cn.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return Ef(e,t,n).then(i=>new Cn(i))}static fromEncryptedJsonSync(e,t){return new Cn(If(e,t))}static fromMnemonic(e,t,n){return t||(t=fa),new Cn(It.fromMnemonic(e,null,n).derivePath(t))}};function Rf(a,e){return fi(Zi(a),e)}function Pf(a,e,t,n){return fi(bt.hash(a,e,t),n)}var Zn={};ji(Zn,{AlchemyProvider:()=>wr,AlchemyWebSocketProvider:()=>ms,AnkrProvider:()=>hs,BaseProvider:()=>Yn,CloudflareProvider:()=>xs,EtherscanProvider:()=>bs,FallbackProvider:()=>Ts,Formatter:()=>Y,InfuraProvider:()=>kr,InfuraWebSocketProvider:()=>ws,IpcProvider:()=>_l,JsonRpcBatchProvider:()=>Zo,JsonRpcProvider:()=>Yt,JsonRpcSigner:()=>Tr,NodesmithProvider:()=>_s,PocketProvider:()=>ks,Provider:()=>$t,Resolver:()=>gr,StaticJsonRpcProvider:()=>cs,UrlJsonRpcProvider:()=>Ct,Web3Provider:()=>As,WebSocketProvider:()=>ba,getDefaultProvider:()=>eu,getNetwork:()=>rs,isCommunityResourcable:()=>fl,isCommunityResource:()=>us,showThrottleMessage:()=>Xn});var Nf="networks/5.7.1";var Df=new M(Nf);function W5(a){return a&&typeof a.renetwork=="function"}function ha(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return ha(t)},e}function Vo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return Vo(a,n)},t}var Of={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:ha("homestead")},Bf={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:ha("ropsten")},Ff={chainId:63,name:"classicMordor",_defaultProvider:Vo("https://www.ethercluster.com/mordor","classicMordor")},Uo={unspecified:{chainId:0,name:"unspecified"},homestead:Of,mainnet:Of,morden:{chainId:2,name:"morden"},ropsten:Bf,testnet:Bf,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:ha("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:ha("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:ha("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:ha("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Vo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Ff,classicTestnet:Ff,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Vo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:ha("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:ha("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function rs(a){if(a==null)return null;if(typeof a=="number"){for(let n in Uo){let i=Uo[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=Uo[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=Uo[a.name];if(!e)return typeof a.chainId!="number"&&Df.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&Df.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(W5(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Lf="web/5.7.1";var K5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Uf(a,e){return K5(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var J5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Sn=new M(Lf);function Vf(a){return new Promise(e=>{setTimeout(e,a)})}function Na(a,e){if(a==null)return null;if(typeof a=="string")return a;if(na(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Jt(a)}catch{}return W(a)}return a}function $5(a){return ve(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function pl(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Sn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Sn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},f=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Sn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(f=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Sn.throwError("basic authentication requires a secure https url",M.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+Yi(ve(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?Xi(_[3]):$5(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Sn.throwError("processing response error",M.errors.SERVER_ERROR,{body:Na(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(E,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Sn.makeError("timeout",M.errors.TIMEOUT,{requestBody:Na(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return J5(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Sn.throwError("bad response",M.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Na(H,U.headers?U.headers["content-type"]:null),requestBody:Na(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let E=yield t(H,U);return S.cancel(),E}catch(E){if(E.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Jt(r))}catch(l){Sn.throwError("invalid JSON",M.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=ve(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return pl(a,i,n)}function Pn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(f){if(f!==void 0)s()&&t(f);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(f){s()&&n(f)})}p()})}var xl=_n(Gf());var Ae="providers/5.7.2";var os=new M(Ae),Y=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),f=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:Y.allowNull(this.accessList.bind(this),null),blockHash:Y.allowNull(s,null),blockNumber:Y.allowNull(l,null),transactionIndex:Y.allowNull(l,null),confirmations:Y.allowNull(l,null),from:t,gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),gasLimit:n,to:Y.allowNull(t,null),value:n,nonce:l,data:r,r:Y.allowNull(this.uint256),s:Y.allowNull(this.uint256),v:Y.allowNull(l),creates:Y.allowNull(t,null),raw:Y.allowNull(r)},e.transactionRequest={from:Y.allowNull(t),nonce:Y.allowNull(l),gasLimit:Y.allowNull(n),gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),to:Y.allowNull(t),value:Y.allowNull(n),data:Y.allowNull(f),type:Y.allowNull(l),accessList:Y.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:Y.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:Y.allowNull(this.address,null),from:Y.allowNull(this.address,null),contractAddress:Y.allowNull(t,null),transactionIndex:l,root:Y.allowNull(o),gasUsed:n,logsBloom:Y.allowNull(r),blockHash:s,transactionHash:s,logs:Y.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:Y.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:Y.allowNull(n),status:Y.allowNull(l),type:p},e.block={hash:Y.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:Y.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:Y.allowNull(t),extraData:r,transactions:Y.allowNull(Y.arrayOf(s)),baseFeePerGas:Y.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=Y.allowNull(Y.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:Y.allowNull(i,void 0),toBlock:Y.allowNull(i,void 0),blockHash:Y.allowNull(s,void 0),address:Y.allowNull(t,void 0),topics:Y.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:Y.allowNull(l),blockHash:Y.allowNull(s),transactionIndex:l,removed:Y.allowNull(this.boolean.bind(this)),address:t,data:Y.allowFalsish(r,"0x"),topics:Y.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return sn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ae(e))?e.toLowerCase():os.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ce(e)}callAddress(e){if(!ae(e,32))return null;let t=ce(Ie(e,12));return t===io?null:t}contractAddress(e){return di(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ae(e))return Fn(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Pt(n)!==32?os.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ae(e))throw new Error("invalid uint256");return me(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=Y.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return Y.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=Y.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ae(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ae(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return Eo(e)}receiptLog(e){return Y.check(this.formats.receiptLog,e)}receipt(e){let t=Y.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&os.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):os.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&os.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return Y.check(this.formats.filter,e)}filterLog(e){return Y.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function fl(a){return a&&typeof a.isCommunityResource=="function"}function us(a){return fl(a)&&a.isCommunityResource()}var zf=!1;function Xn(){zf||(zf=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},he=new M(Ae),ax=10;function Wf(a){return a==null?"null":(Pt(a)!==32&&he.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function Kf(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[Wf(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return Wf(e)}).join("&")}function ix(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function br(a){if(typeof a=="string"){if(a=a.toLowerCase(),Pt(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+Kf(a);if(ho.isForkEvent(a))throw he.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+Kf(a.topics||[])}throw new Error("invalid event - "+a)}function ds(){return new Date().getTime()}function Jf(a){return new Promise(e=>{setTimeout(e,a)})}var rx=["block","network","pending","poll"],bl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=ix(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||rx.indexOf(this.tag)>=0}},sx={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function cl(a){return me(F.from(a).toHexString(),32)}function $f(a){return pa.encode(ye([a,Ie(Xt(Xt(a)),0,4)]))}var Yf=new RegExp("^(ipfs)://(.*)$","i"),Qf=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Yf,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Go(a,e){try{return Jt(ls(a,e))}catch{}return null}function ls(a,e){if(a==="0x")return null;let t=F.from(Ie(a,e,e+32)).toNumber(),n=F.from(Ie(a,t,t+32)).toNumber();return Ie(a,t+32,t+32+n)}function ml(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):he.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function Xf(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function ox(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function Zf(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===M.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:kt([e,Ea(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=kt(["0x9061b923",Zf([Jr(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&he.throwError("resolver threw error",M.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=ls(r,0)),r}catch(r){if(r.code===M.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?ls(n,0):null})}_getAddress(e,t){let n=sx[String(e)];if(n==null&&he.throwError(`unsupported coin type: ${e}`,M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return $f(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return $f(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=xl.default.toWords(i.slice(2));return o.unshift(s),xl.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===$i?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===M.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",cl(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&he.throwError("invalid or unsupported coin data",M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return he.throwError("invalid or unsupported content hash data",M.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=ve(e);t=ye([cl(64),cl(t.length),t]),t.length%32!==0&&(t=ye([t,me("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Jt(n)})}},hl=null,ux=1,Yn=class extends $t{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=ht(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):he.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||he.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Pn(()=>this._ready().then(e=>e,e=>{if(!(e.code===M.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return hl==null&&(hl=new Y),hl}static getNetwork(e){return rs(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Rn({url:p,errorPassThrough:!0},f,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return he.throwError(`response not found during CCIP fetch: ${C}`,M.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return he.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,M.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(ds()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=ds(),n=Ce({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=ds();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=ux++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)he.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",he.makeError("network block skew detected",M.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return he.throwError("provider does not support network detection",M.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield Jf(0),this._network;let n=he.makeError("underlying network changed",M.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=ds();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,f=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield Jf(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{f()||o(he.makeError("timeout exceeded",M.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Fn(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Pt(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&he.throwError("Transaction hash mismatch from Provider.sendTransaction.",M.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&he.throwError("transaction failed",M.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Ce(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Ce(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=ax&&he.throwError("CCIP read exceeded maximum redirections",M.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Pt(r)%32===4)try{let s=Ie(r,4),o=Ie(s,0,32);F.from(o).eq(i)||he.throwError("CCIP Read sender did not match",M.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ie(s,32,64)).toNumber(),f=F.from(Ie(s,p,p+32)).toNumber(),x=Ie(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Ce({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),Y.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&he.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new gr(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||he.throwError("network does not support ENS",M.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Ea(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ae(e))throw n}typeof e!="string"&&he.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=Go(yield this.call({to:n,data:"0x691f3431"+Ea(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ae(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new gr(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o}try{let o=Go(yield this.call({to:s,data:"0x691f3431"+Ea(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return he.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new bl(br(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=br(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=br(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=br(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=br(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=br(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var xa=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Mt=new M(Ae),dx=["call","estimateGas"];function ys(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ae(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=ys(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return ys(JSON.parse(a),e)}catch{}return null}function tc(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=ys(e,!0);if(r)return r.data;Mt.throwError("missing revert data in call exception; Transaction reverted without a reason string",M.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=ys(e.body,!1);r==null&&(r=ys(e,!1)),r&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===M.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Mt.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Mt.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Mt.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Mt.throwError("legacy pre-eip-155 transactions not supported",M.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),dx.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function ec(a){return new Promise(function(e){setTimeout(e,a)})}function lx(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function ps(a){return a&&a.toLowerCase()}var gl={},Tr=class extends Bt{constructor(e,t,n){if(super(),e!==gl)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Mt.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Mt.throwError("cannot alter JSON-RPC Signer connection",M.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new Tl(gl,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Mt.throwError("unknown account #"+this._index,M.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>xa(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Mt.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Ce({tx:Ce(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Mt.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected transaction",M.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),tc("sendTransaction",s,r)))})}signTransaction(e){return Mt.throwError("signing transactions is unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return xa(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Pn(()=>xa(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return xa(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return xa(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return xa(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(bt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return xa(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},Tl=class extends Tr{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},px={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},Yt=class extends Yn{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=ht(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return xa(this,void 0,void 0,function*(){yield ec(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=ht(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new Tr(gl,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:mt(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Rn(this.connection,JSON.stringify(n),lx).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ps(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ps(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ps(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ps(t.address),me(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=ht(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=ht(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=ps(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return xa(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Mt.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return tc(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return ec(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(px);if(t)for(let r in t)t[r]&&(n[r]=!0);Gi(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Fn(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=sn(e.accessList)),i}};var vr=null;try{if(vr=WebSocket,vr==null)throw new Error("inject please")}catch{let e=new M(Ae);vr=function(){e.throwError("WebSockets not supported in this environment",M.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var vl=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},zo=new M(Ae),yx=1,ba=class extends Yt{constructor(e,t){t==="any"&&zo.throwError("WebSocketProvider does not support 'any' network yet",M.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new vr(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){zo.throwError("cannot reset events block on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){zo.throwError("cannot set polling interval on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return vl(this,void 0,void 0,function*(){return null})}set polling(e){!e||zo.throwError("cannot set polling on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=yx++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return vl(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return vl(this,void 0,void 0,function*(){this.websocket.readyState===vr.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var fx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},fs=new M(Ae),cs=class extends Yt{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return fx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||fs.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Ct=class extends cs{constructor(e,t){fs.checkAbstract(new.target,Ct),e=ht(new.target,"getNetwork")(e),t=ht(new.target,"getApiKey")(t);let n=ht(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){fs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return fs.throwError("API provider does not support signing",M.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return fs.throwError("not implemented; sub-classes must override getUrl",M.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var nc=new M(Ae),Wo="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",ms=class extends ba{constructor(e,t){let n=new wr(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===Wo}},wr=class extends Ct{static getWebSocketProvider(e,t){return new ms(e,t)}static getApiKey(e){return e==null?Wo:(e&&typeof e!="string"&&nc.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:nc.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===Wo&&Xn(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===Wo}};var cx=new M(Ae),Ko="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function mx(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return cx.throwArgumentError("unsupported network","name",a)}var hs=class extends Ct{isCommunityResource(){return this.apiKey===Ko}static getApiKey(e){return e??Ko}static getUrl(e,t){t==null&&(t=Ko);let n={allowGzip:!0,url:"https://"+mx(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===Ko&&Xn(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var hx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},ac=new M(Ae),xs=class extends Ct{static getApiKey(e){return e!=null&&ac.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:ac.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return hx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var Jo=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Da=new M(Ae);function ic(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Fn(W(n)):t==="accessList"?n="["+sn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function xx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function rc(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function sc(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function wl(a,e,t){if(a==="call"&&e.code===M.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ae(r))return r;Da.throwError("missing revert data in call exception",M.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===M.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Da.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Da.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Da.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Da.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var bs=class extends Yn{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Da.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return Jo(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?rc:xx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(f,x)=>(this.isCommunityResource()&&Xn(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(f=>`${f}=${r[f]}`).join("&"));let p=yield Rn(o,l,s||rc);return this.emit("debug",{action:"response",request:i,response:mt(p),provider:this}),p})}detectNetwork(){return Jo(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return Jo(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>wl("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=ic(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return wl("call",r,t.transaction)}}case"estimateGas":{let i=ic(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return wl("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=sc(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=sc(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Da.throwError("unsupported topic count",M.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Da.throwError("unsupported topic format",M.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var Xo=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},gi=new M(Ae);function $o(){return new Date().getTime()}function oc(a){let e=null;for(let t=0;te?null:(n+i)/2}function _r(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>_r(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=_r(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var bx=1;function dc(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var gx=[M.errors.CALL_EXCEPTION,M.errors.INSUFFICIENT_FUNDS,M.errors.NONCE_EXPIRED,M.errors.REPLACEMENT_UNDERPRICED,M.errors.UNPREDICTABLE_GAS_LIMIT],Tx=["address","args","errorArgs","errorSignature","method","transaction"];function Qo(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function vx(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function wx(a,e,t){let n=_r;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=uc(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return uc(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,_r(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),_r(i))}:n=function(i){return i==null?null:_r(i)};break;default:throw new Error("unknown method: "+e)}return vx(n,a.quorum)}function gs(a,e){return Xo(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Pn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function _x(a,e,t,n){return Xo(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ae(n.blockTag)&&(i=yield gs(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ae(n.blockTag)&&(i=yield gs(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ae(n.blockTag)&&(i=yield gs(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ae(n.blockTag)&&(i=yield gs(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ae(r.fromBlock)||r.toBlock&&ae(r.toBlock))&&(i=yield gs(a,e)),i.getLogs(r)}}return gi.throwError("unknown method error",M.errors.UNKNOWN_ERROR,{method:t,params:n})})}var Ts=class extends Yn{constructor(e,t){e.length===0&&gi.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if($t.isProvider(s)){let f=us(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:f,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=us(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&gi.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&gi.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=oc(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return Xo(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return oc(e)})}perform(e,t){return Xo(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(f=>f.hash,f=>f)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=$o(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=_x(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Qo(_,$o()),request:{method:e,params:mt(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Qo(_,$o()),request:{method:e,params:mt(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Qo(_,null),request:{method:e,params:mt(t)},provider:this}),p+=_.weight}let f=[];i.forEach(_=>{_.done||!_.runner||(f.push(_.runner),_.staller&&f.push(_.staller.getPromise()))}),f.length&&(yield Promise.race(f));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield dc(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return gx.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};Tx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),gi.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),gi.throwError("failed to meet quorum",M.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>Qo(l)),provider:this})})}};var _l=null;var Yo=new M(Ae),vs="84842078b09946638c03157f83405213",ws=class extends ba{constructor(e,t){let n=new kr(e,t),i=n.connection;i.password&&Yo.throwError("INFURA WebSocket project secrets unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===vs}},kr=class extends Ct{static getWebSocketProvider(e,t){return new ws(e,t)}static getApiKey(e){let t={apiKey:vs,projectId:vs,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(Yo.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),Yo.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:Yo.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===vs&&Xn(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===vs}};var Zo=class extends Yt{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:mt(o),provider:this}),Rn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,f)=>{let x=l[f];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var kl=new M(Ae),kx="ETHERS_JS_SHARED",_s=class extends Ct{static getApiKey(e){return e&&typeof e!="string"&&kl.throwArgumentError("invalid apiKey","apiKey",e),e||kx}static getUrl(e,t){kl.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:kl.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var lc=new M(Ae),pc="62e1ad51b37b8e00394bda3b",ks=class extends Ct{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=pc:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:lc.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:lc.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===pc}};var yc=new M(Ae),Ax=1;function fc(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:Ax++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:mt(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let f=new Error(p.error.message);return f.code=p.error.code,f.data=p.error.data,o(f)}s(p.result)})})}}function Mx(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:mt(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var As=class extends Yt{constructor(e,t){e==null&&yc.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Mx(e)):e.sendAsync?i=fc(e,e.sendAsync.bind(e)):e.send?i=fc(e,e.send.bind(e)):yc.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var cc=new M(Ae);function eu(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new Yt(a);case"ws":case"wss":return new ba(a);default:cc.throwArgumentError("unsupported URL scheme","network",a)}}let t=rs(a);return(!t||!t._defaultProvider)&&cc.throwError("unsupported getDefaultProvider network",M.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:Ts,AlchemyProvider:wr,AnkrProvider:hs,CloudflareProvider:xs,EtherscanProvider:bs,InfuraProvider:kr,JsonRpcProvider:Yt,NodesmithProvider:_s,PocketProvider:ks,Web3Provider:As,IpcProvider:null},e)}var te={};ji(te,{AbiCoder:()=>Qi,ConstructorFragment:()=>Nt,ErrorFragment:()=>tn,EventFragment:()=>Ht,FormatTypes:()=>ge,Fragment:()=>qt,FunctionFragment:()=>Dt,HDNode:()=>It,Indexed:()=>sa,Interface:()=>Ia,LogDescription:()=>er,Logger:()=>M,ParamType:()=>pt,RLP:()=>Qs,SigningKey:()=>cn,SupportedAlgorithm:()=>$n,TransactionDescription:()=>tr,TransactionTypes:()=>Mo,UnicodeNormalizationForm:()=>Gt,Utf8ErrorFuncs:()=>lo,Utf8ErrorReason:()=>Ot,_TypedDataEncoder:()=>bt,_fetchData:()=>pl,_toEscapedUtf8String:()=>hd,accessListify:()=>sn,arrayify:()=>j,base58:()=>pa,base64:()=>wd,checkProperties:()=>Gi,checkResultErrors:()=>Wi,commify:()=>wc,computeAddress:()=>mn,computeHmac:()=>ya,computePublicKey:()=>Xr,concat:()=>ye,deepCopy:()=>mt,defaultAbiCoder:()=>Wr,defaultPath:()=>fa,defineReadOnly:()=>B,dnsEncode:()=>Jr,entropyToMnemonic:()=>bi,fetchJson:()=>Rn,formatBytes32String:()=>xd,formatEther:()=>_c,formatUnits:()=>Al,getAccountPath:()=>cf,getAddress:()=>ce,getContractAddress:()=>di,getCreate2Address:()=>Ey,getIcapAddress:()=>My,getJsonWalletAddress:()=>sl,getStatic:()=>ht,hashMessage:()=>Zi,hexConcat:()=>kt,hexDataLength:()=>Pt,hexDataSlice:()=>Ie,hexStripZeros:()=>rd,hexValue:()=>Fn,hexZeroPad:()=>me,hexlify:()=>W,id:()=>nn,isAddress:()=>Ay,isBytes:()=>on,isBytesLike:()=>na,isHexString:()=>ae,isValidMnemonic:()=>ff,isValidName:()=>kd,joinSignature:()=>Br,keccak256:()=>fe,mnemonicToEntropy:()=>cr,mnemonicToSeed:()=>Zd,namehash:()=>Ea,nameprep:()=>vd,parseBytes32String:()=>bd,parseEther:()=>kc,parseTransaction:()=>Eo,parseUnits:()=>Ml,poll:()=>Pn,randomBytes:()=>Qn,recoverAddress:()=>fi,recoverPublicKey:()=>Ao,resolveProperties:()=>Ce,ripemd160:()=>es,serializeTransaction:()=>Yr,sha256:()=>Xt,sha512:()=>$d,shallowCopy:()=>_e,shuffled:()=>as,solidityKeccak256:()=>xc,solidityPack:()=>tu,soliditySha256:()=>bc,splitSignature:()=>Ln,stripZeros:()=>Zt,toUtf8Bytes:()=>ve,toUtf8CodePoints:()=>Ma,toUtf8String:()=>Jt,verifyMessage:()=>Rf,verifyTypedData:()=>Pf,zeroPad:()=>ri});var mc="solidity/5.7.0";var Ex=new RegExp("^bytes([0-9]+)$"),Ix=new RegExp("^(u?int)([0-9]*)$"),Cx=new RegExp("^(.*)\\[([0-9]*)\\]$"),Sx="0000000000000000000000000000000000000000000000000000000000000000",Ar=new M(mc);function hc(a,e,t){switch(a){case"address":return t?ri(e,32):j(e);case"string":return ve(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?ri(e,32):j(e)}let n=a.match(Ix);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Ar.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),ri(e,i/8)}if(n=a.match(Ex),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Ar.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Ar.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+Sx).substring(0,66)):e}if(n=a.match(Cx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Ar.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(hc(i,o,!0))}),ye(s)}return Ar.throwArgumentError("invalid type","type",a)}function tu(a,e){a.length!=e.length&&Ar.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(hc(n,e[i]))}),W(ye(t))}function xc(a,e){return fe(tu(a,e))}function bc(a,e){return Xt(tu(a,e))}var gc="units/5.7.0";var Tc=new M(gc),vc=["wei","kwei","mwei","gwei","szabo","finney","ether"];function wc(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&Tc.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Al(a,e){if(typeof e=="string"){let t=vc.indexOf(e);t!==-1&&(e=3*t)}return qi(a,e??18)}function Ml(a,e){if(typeof a!="string"&&Tc.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=vc.indexOf(e);t!==-1&&(e=3*t)}return dn(a,e??18)}function _c(a){return Al(a,18)}function kc(a){return Ml(a,18)}var nu="ethers/5.7.2";var Ac=new M(nu);try{let a=window;a._ethers==null&&(a._ethers=El)}catch{}var ga;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(ga||(ga={}));var Il;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(Il||(Il={}));var Ms;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Ms||(Ms={}));var Cl;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(Cl||(Cl={}));var Es;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Es||(Es={}));var Sl;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Sl||(Sl={}));var Rl;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Rl||(Rl={}));var Pl;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(Pl||(Pl={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var zt;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(zt||(zt={}));var Dl="0x12345678",Nl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(Nl||(Nl={}));var vt;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(vt||(vt={}));var we;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(we||(we={}));var Ol=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],Ti=class{static createInterface(){return new te.Interface(Ol)}static connect(e,t){return new oe(e,Ol,t)}};xe(Ti,"abi",Ol);var Bl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],vi=class{static createInterface(){return new te.Interface(Bl)}static connect(e,t){return new oe(e,Bl,t)}};xe(vi,"abi",Bl);var Mc=(a,e)=>{throw new Error(`${e}: ${a}`)},Fl=a=>a!=null;var{keccak256:Px,toUtf8Bytes:Nx}=te,{MaxUint256:Dx}=yt,Ll=(a,e)=>a.toLowerCase()===e.toLowerCase(),Ul=a=>te.formatEther(a);var Vl=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(vt.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(Fl)},wi=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return Dx;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},Oa=a=>Px(Nx(a));var Mr=async(a,e)=>(await vi.connect(a,e).version()).toNumber(),jl=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(Fl);var{hexDataSlice:Hl}=te,{MaxUint256:Ox}=yt,Ec=a=>{let e=Hl(a,0,3),t=F.from(Hl(a,4,35)),n=F.from(Hl(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Ic=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),Ox,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await wi(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},Bx=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Ic(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?ea(a,e,t,n[0],i):Bx(a,e,t,n,i):Ic(a,e,t,n,i);var{MaxUint256:Cc}=yt,{AddressZero:Fx}=yt;async function Lx(a,e){let t;try{return t=await a.getCapabilityRoles(te.hexZeroPad(e,4)),au(t)}catch{return[]}}async function Is(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:f,childSkillIndex:x}=Ec(s),C=Ti.connect(r,n.signer||n.provider),_=await Lx(C,p);if(_.includes(vt.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Cc}else{let{skillId:U}=await e.getDomain(f),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Cc;else{let{children:E}=await a.getSkill(l),J=E.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,Fx);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:Ux}=yt,ta=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||ga.Gnosis;this.endpointUrl=n?.customEndpointUrl||Ms[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await ta.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await ta.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await ta.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let f=p+1,x=await this.colony.getDomain(f);return{domainId:f,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,f=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return f&&(p=f?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return ta.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${Ux}/noProof`,s=await ta.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var _t=a=>Array.from(Array(a-1)).map(e=>e+1);var Sc=10,Ck=_t(Sc),Rc={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},Pc=Sc-1;var Nc=6,Pk=_t(Nc),Dc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},Oc=Nc-1;var Bc=7,Ok=_t(Bc),Fc={1:[],2:[],3:[],4:[],5:[],6:[]},Lc=Bc-1;var Uc=7,Lk=_t(Uc),Vc={1:[],2:[],3:[],4:[],5:[],6:[]},jc=Uc-1;var Hc=4,jk=_t(Hc),qc={1:[],2:[],3:[]},Gc=Hc-1;var zc=5,Gk=_t(zc),Wc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},Kc=zc-1;var Jc=2,Kk=_t(Jc),$c={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},Qc=Jc-1;var Xc=4,Qk=_t(Xc),Yc={1:[1,2,3],2:[1,2,3],3:[1,2,3]},Zc=Xc-1;var em=7,Zk=_t(em),tm={1:[],2:[],3:[],4:[],5:[],6:[]},nm=em-1;var am=11,nA=_t(am),ql={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Gl=am-1;var im=6,rA=_t(im),rm={1:[],2:[],3:[],4:[],5:[]},sm=im-1;var Ba=(a,e,t)=>{switch(a){case we.CoinMachine:{let n=Rc[e];return!!n&&!n.includes(t)}case we.EvaluatedExpenditure:{let n=Dc[e];return!!n&&!n.includes(t)}case we.FundingQueue:{let n=Fc[e];return!!n&&!n.includes(t)}case we.IVotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.OneTxPayment:{let n=Vc[e];return!!n&&!n.includes(t)}case we.ReputationBootstrapper:{let n=qc[e];return!!n&&!n.includes(t)}case we.StagedExpenditure:{let n=$c[e];return!!n&&!n.includes(t)}case we.StakedExpenditure:{let n=Wc[e];return!!n&&!n.includes(t)}case we.StreamingPayments:{let n=Yc[e];return!!n&&!n.includes(t)}case we.TokenSupplier:{let n=tm[e];return!!n&&!n.includes(t)}case we.VotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.Whitelist:{let n=rm[e];return!!n&&!n.includes(t)}default:return Mc(a,"Could not find extension with name")}};var Vx={[we.CoinMachine]:Pc,[we.EvaluatedExpenditure]:Oc,[we.FundingQueue]:Lc,[we.IVotingReputation]:Gl,[we.OneTxPayment]:jc,[we.ReputationBootstrapper]:Gc,[we.StagedExpenditure]:Qc,[we.StakedExpenditure]:Kc,[we.StreamingPayments]:Zc,[we.TokenSupplier]:nm,[we.VotingReputation]:Gl,[we.Whitelist]:sm};var Ih=_n(om(),1);var yp=_n(Ah(),1);var Re;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Re||(Re={}));var pp=2,lp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(lp||(lp={}));var Mh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,Zb=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Mh(t.errors);throw new Error(n)};var Eh=(a,e)=>{let t=a===Re.Colony?Zb(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:pp});if(!n.success){let i=Mh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ih.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Bs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Ua=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Bs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Bs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Eh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var PM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=async(a,e)=>{let t=await a;return e.send("eth_getLogs",[t])},Fs=a=>a!=null;var Va=class{ipfs;provider;constructor(e,t){this.ipfs=new Ua(t?.ipfsAdapter),this.provider=e}static extractSingleTopic(e){if(!e||!e.topics)return null;let t=e.topics;return typeof t[0]=="string"?t[0]:Array.isArray(t[0])&&typeof t[0][0]=="string"?t[0][0]:null}createEventSource(e){return e.connect(yt.AddressZero,this.provider)}async getEvents(e){return(await xp(e,this.provider)).map(n=>{let{eventSource:i,eventName:r}=e,s=i.interface.decodeEventLog(r,n.data,n.topics);return Ua.eventSupportsMetadata(r)?{...e,data:s,transactionHash:n.transactionHash,getMetadata:async()=>await this.ipfs.getMetadataForEvent(r,s.metadata)}:{...e,transactionHash:n.transactionHash,data:s}}).filter(Fs)}async getMultiEvents(e,t={}){let n=[].concat(e),i=Array.from(new Set(n.flatMap(({address:o})=>o))).filter(Fs),r=Array.from(new Set(n.flatMap(({colonyTopics:o})=>o.map(({topic:l})=>l))));return(await xp({address:i.length?i:void 0,fromBlock:t.fromBlock,toBlock:t.toBlock,topics:[r]},this.provider)).map(o=>{let l=Va.extractSingleTopic(o),p=n.find(({address:S,colonyTopics:L})=>S&&!Ll(S,o.address)?!1:L.findIndex(({topic:O})=>O===l)>-1);if(!p)return null;let f=p.colonyTopics.find(({topic:S})=>S===l);if(!f)return null;let{eventSource:x,eventName:C}=f,_=x.interface.decodeEventLog(C,o.data,o.topics),v={address:o.address,eventSource:x,topics:o.topics,eventName:C,data:_,transactionHash:o.transactionHash};return Ua.eventSupportsMetadata(C)?{...v,getMetadata:async()=>await this.ipfs.getMetadataForEvent(C,_.metadata)}:v}).filter(Fs)}createFilter(e,t,n,i,r={}){let s=i?e.filters[t].apply([e.filters[t],...i]):e.filters[t]();return{eventSource:e,eventName:t,topics:s.topics,address:n,fromBlock:r.fromBlock,toBlock:r.toBlock}}createMultiFilter(e,t,n){let i=t.map(r=>{let s=this.createFilter(e,r,n),o=Va.extractSingleTopic(s);return o?{topic:o,eventName:r,eventSource:s.eventSource}:null}).filter(Fs);return{address:n,colonyTopics:i}}};var bp=[{anonymous:!1,inputs:[{indexed:!1,name:"colonyNetwork",type:"address"},{indexed:!1,name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"users",type:"address[]"},{indexed:!1,name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"oldVersion",type:"uint256"},{indexed:!1,name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"user",type:"address"},{indexed:!0,name:"domainId",type:"uint256"},{indexed:!0,name:"role",type:"uint8"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"fromPot",type:"uint256"},{indexed:!0,name:"toPot",type:"uint256"},{indexed:!1,name:"amount",type:"uint256"},{indexed:!1,name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"token",type:"address"},{indexed:!1,name:"fee",type:"uint256"},{indexed:!1,name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardPayoutId",type:"uint256"},{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"fee",type:"uint256"},{indexed:!1,name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!0,name:"domainId",type:"uint256"}],name:"TaskDomainSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!0,name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"role",type:"uint8"},{indexed:!0,name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"role",type:"uint8"},{indexed:!1,name:"token",type:"address"},{indexed:!1,name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"role",type:"uint8"},{indexed:!1,name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"fundingPotId",type:"uint256"},{indexed:!1,name:"token",type:"address"},{indexed:!1,name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"slot",type:"uint256"},{indexed:!0,name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"slot",type:"uint256"},{indexed:!0,name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"slot",type:"uint256"},{indexed:!0,name:"token",type:"address"},{indexed:!1,name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyFundingRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyAdministrationRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyArchitectureRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyRootRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"id",type:"uint256"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"tokenPayout",type:"uint256"}],name:"PayoutClaimed",type:"event"}],Ii=class{static createInterface(){return new te.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(Ii,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new te.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Tn,"abi",gp);var Tp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new te.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(vn,"abi",Tp);var vp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ci=class{static createInterface(){return new te.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Fu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Ch="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",T1=a=>a.length>1,Nn=class extends mi{constructor(...e){T1(e)?super(...e):super(Fu,Ch,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Fu)}static connect(e,t){return new oe(e,Fu,t)}};xe(Nn,"bytecode",Ch),xe(Nn,"abi",Fu);var wp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Si=class{static createInterface(){return new te.Interface(wp)}static connect(e,t){return new oe(e,wp,t)}};xe(Si,"abi",wp);var Rr;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Rr||(Rr={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Rh}=yt;async function _1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var k1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Nn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await _1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Rh)}catch{i=!1}try{await t.nonces(Rh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Si.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Rr.TokenClient,t},_p=k1;var{AddressZero:kp}=yt,M1=Tn.connect(kp,new Zn.BaseProvider(3656691)).interface,E1=Ci.connect(kp,new Zn.BaseProvider(3656691)).interface,I1=vn.connect(kp,new Zn.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ls=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Ls.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Us=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};Us.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Pr=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Pr.abi=Ep;var Ri=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Bs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:S1,solidityKeccak256:R1,splitSignature:P1}=te,Nr=class extends Ri{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===ga.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=R1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=S1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=P1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ie=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Lu=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Pi=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Pi.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Ni.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Di.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Oi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Bi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Fi.abi=Np;var{AddressZero:U1}=yt,Dn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Oa(Dn.extensionType),e.address);if(t===U1)throw new Error(`${Dn.extensionType} extension is not installed for this Colony`);let n=await Mr(t,e.colonyNetwork.signerOrProvider);if(!Ba(Dn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Dn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Dn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Dn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Dn(e,r,n)}static getLatestSupportedVersion(){return Dn.supportedVersions[Dn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ea(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ea(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ie("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Oa(we.OneTxPayment),t],async n=>({...ie("ExtensionUpgraded",n)}))}},ja=Dn;ja.supportedVersions=[{version:3,factory:Oi},{version:4,factory:Bi},{version:5,factory:Fi}],ja.extensionType=we.OneTxPayment;var On=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ie("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ie("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ie("Approval",n)}))}};var Vs=class extends On{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Nn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ie("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ie("LogSetOwner",n)}))}};var js=class extends On{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ie("Approval",i)}))}};var Ph=async(a,e)=>{let t=await _p(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new Vs(a,t);case wn.Erc20:return new On(a,t);case wn.Erc2612:return new js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Li.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Ui.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Vi.abi=Bp;var{AddressZero:Fp}=yt;var Uu=F.from(10).pow(18),Bn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Oa(Bn.extensionType),e.address);if(t===Fp)throw new Error(`${Bn.extensionType} extension is not installed for this Colony`);let n=await Mr(t,e.colonyNetwork.signerOrProvider);if(!Ba(Bn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Bn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Bn(e,r,n)}static getLatestSupportedVersion(){return Bn.supportedVersions[Bn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ie("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Is(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Dl);return[e,t,Fp,Dl,n,i,r,s]},async t=>({...ie("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ie("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Lu("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ea(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ie("MotionStaked",r),...ie("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ie("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ie("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await wi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ie("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ie("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Oa(we.VotingReputation),t],async n=>({...ie("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ha=Bn;Ha.supportedVersions=[{version:7,factory:Li},{version:8,factory:Ui},{version:9,factory:Vi}],Ha.extensionType=we.VotingReputation;var q1={["motion"]:Ha,["oneTx"]:ja},Or=class{static async connect(e,t){let n=await Mr(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Ph(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new ta(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ha.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new On(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ie("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ie("DomainAdded",t),...ie("FundingPotAdded",t),...ie("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ie("DomainAdded",t),...ie("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ie("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ie("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ie("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ea(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await wi(x,this.colony,r,s),_=await wi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ie("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ie("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ie("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=q1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Ba(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Oa(i),t.getLatestSupportedVersion()],async s=>({...Lu("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return au(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ie("ColonyRoleSet",i),...ie("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ie("ColonyRoleSet",i),...ie("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ie("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ie("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ie("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ie("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ie("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ie("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ie("ArbitraryReputationUpdate",i)}))}},Hs=Or;Hs.supportedVersions=[{version:11,factory:Pi},{version:12,factory:Ni},{version:13,factory:Di}];var{splitSignature:xP}=te;var{namehash:LP}=te,{AddressZero:UP}=yt;var z1=new Zn.JsonRpcProvider(Es.Gnosis),{isAddress:W1}=te,K1=(a,e)=>{let t=new Va(z1),n=t.createEventSource(Ii),i=t.createMultiFilter(n,["DomainAdded(address,uint256)","DomainMetadata(address,uint256,string)"],a),r=0;t.provider.on("block",async s=>{if(r+=1,r===4){let o=await t.getMultiEvents(i,{fromBlock:s-r,toBlock:s});o.length&&e(o),r=0}})},Up=document.querySelector("#address"),Nh=document.querySelector("#button"),Vp=document.querySelector("#error"),Dh=document.querySelector("#result");if(!Up||!Nh||!Vp||!Dh)throw new Error("Could not find all required HTML elements");var J1=a=>{Vp.innerText=a},$1=()=>{Vp.innerText=""},Lp=a=>{Dh.innerText=a};Nh.addEventListener("click",async()=>{$1();let a=Up.value;return W1(a)?(Up.value="",K1(a,e=>{Lp(`A domain with id ${e[0].data.domainId} was created on Colony ${e[0].address}.`),e.forEach(async t=>{if(t.getMetadata){let n=await t.getMetadata();if(n.name===Re.Domain){let{domainName:i,domainColor:r,domainPurpose:s}=n.data;Lp(`A domain with id ${t.data.domainId} was created on Colony ${t.address}. It's name is ${i}, it's color ${r} and was created for the following purpose: ${s}`)}}})}),Lp(`Set up event listener for Colony ${a}`),null):J1("This is not a valid address")});})(); +`)}`,Zb=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Mh(t.errors);throw new Error(n)};var Eh=(a,e)=>{let t=a===Re.Colony?Zb(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:pp});if(!n.success){let i=Mh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ih.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Bs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Ua=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Bs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Bs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Eh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var PM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=async(a,e)=>{let t=await a;return e.send("eth_getLogs",[t])},Fs=a=>a!=null;var Va=class{ipfs;provider;constructor(e,t){this.ipfs=new Ua(t?.ipfsAdapter),this.provider=e}static extractSingleTopic(e){if(!e||!e.topics)return null;let t=e.topics;return typeof t[0]=="string"?t[0]:Array.isArray(t[0])&&typeof t[0][0]=="string"?t[0][0]:null}createEventSource(e){return e.connect(yt.AddressZero,this.provider)}async getEvents(e){return(await xp(e,this.provider)).map(n=>{let{eventSource:i,eventName:r}=e,s=i.interface.decodeEventLog(r,n.data,n.topics);return Ua.eventSupportsMetadata(r)?{...e,data:s,transactionHash:n.transactionHash,getMetadata:async()=>await this.ipfs.getMetadataForEvent(r,s.metadata)}:{...e,transactionHash:n.transactionHash,data:s}}).filter(Fs)}async getMultiEvents(e,t={}){let n=[].concat(e),i=Array.from(new Set(n.flatMap(({address:o})=>o))).filter(Fs),r=Array.from(new Set(n.flatMap(({colonyTopics:o})=>o.map(({topic:l})=>l))));return(await xp({address:i.length?i:void 0,fromBlock:t.fromBlock,toBlock:t.toBlock,topics:[r]},this.provider)).map(o=>{let l=Va.extractSingleTopic(o),p=n.find(({address:S,colonyTopics:L})=>S&&!Ll(S,o.address)?!1:L.findIndex(({topic:O})=>O===l)>-1);if(!p)return null;let f=p.colonyTopics.find(({topic:S})=>S===l);if(!f)return null;let{eventSource:x,eventName:C}=f,_=x.interface.decodeEventLog(C,o.data,o.topics),v={address:o.address,eventSource:x,topics:o.topics,eventName:C,data:_,transactionHash:o.transactionHash};return Ua.eventSupportsMetadata(C)?{...v,getMetadata:async()=>await this.ipfs.getMetadataForEvent(C,_.metadata)}:v}).filter(Fs)}createFilter(e,t,n,i,r={}){let s=i?e.filters[t].apply([e.filters[t],...i]):e.filters[t]();return{eventSource:e,eventName:t,topics:s.topics,address:n,fromBlock:r.fromBlock,toBlock:r.toBlock}}createMultiFilter(e,t,n){let i=t.map(r=>{let s=this.createFilter(e,r,n),o=Va.extractSingleTopic(s);return o?{topic:o,eventName:r,eventSource:s.eventSource}:null}).filter(Fs);return{address:n,colonyTopics:i}}};var bp=[{anonymous:!1,inputs:[{indexed:!1,name:"colonyNetwork",type:"address"},{indexed:!1,name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"users",type:"address[]"},{indexed:!1,name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"oldVersion",type:"uint256"},{indexed:!1,name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"user",type:"address"},{indexed:!0,name:"domainId",type:"uint256"},{indexed:!0,name:"role",type:"uint8"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"fromPot",type:"uint256"},{indexed:!0,name:"toPot",type:"uint256"},{indexed:!1,name:"amount",type:"uint256"},{indexed:!1,name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"token",type:"address"},{indexed:!1,name:"fee",type:"uint256"},{indexed:!1,name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardPayoutId",type:"uint256"},{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"fee",type:"uint256"},{indexed:!1,name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!0,name:"domainId",type:"uint256"}],name:"TaskDomainSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!0,name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"role",type:"uint8"},{indexed:!0,name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"role",type:"uint8"},{indexed:!1,name:"token",type:"address"},{indexed:!1,name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"},{indexed:!1,name:"role",type:"uint8"},{indexed:!1,name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"fundingPotId",type:"uint256"},{indexed:!1,name:"token",type:"address"},{indexed:!1,name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"slot",type:"uint256"},{indexed:!0,name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"slot",type:"uint256"},{indexed:!0,name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,name:"expenditureId",type:"uint256"},{indexed:!0,name:"slot",type:"uint256"},{indexed:!0,name:"token",type:"address"},{indexed:!1,name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyFundingRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyAdministrationRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyArchitectureRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,name:"user",type:"address"},{indexed:!1,name:"setTo",type:"bool"}],name:"ColonyRootRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"id",type:"uint256"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"tokenPayout",type:"uint256"}],name:"PayoutClaimed",type:"event"}],Ii=class{static createInterface(){return new te.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(Ii,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new te.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Tn,"abi",gp);var Tp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new te.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(vn,"abi",Tp);var vp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ci=class{static createInterface(){return new te.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Fu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Ch="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",T1=a=>a.length>1,Nn=class extends mi{constructor(...e){T1(e)?super(...e):super(Fu,Ch,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Fu)}static connect(e,t){return new oe(e,Fu,t)}};xe(Nn,"bytecode",Ch),xe(Nn,"abi",Fu);var wp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Si=class{static createInterface(){return new te.Interface(wp)}static connect(e,t){return new oe(e,wp,t)}};xe(Si,"abi",wp);var Rr;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Rr||(Rr={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Rh}=yt;async function _1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var k1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Nn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await _1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Rh)}catch{i=!1}try{await t.nonces(Rh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Si.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Rr.TokenClient,t},_p=k1;var{AddressZero:kp}=yt,M1=Tn.connect(kp,new Zn.BaseProvider(3656691)).interface,E1=Ci.connect(kp,new Zn.BaseProvider(3656691)).interface,I1=vn.connect(kp,new Zn.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ls=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Ls.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Us=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};Us.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Pr=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Pr.abi=Ep;var Ri=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Bs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:S1,solidityKeccak256:R1,splitSignature:P1}=te,Nr=class extends Ri{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===ga.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=R1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=S1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=P1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ie=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Lu=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Pi=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Pi.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Ni.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Di.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Oi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Bi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Fi.abi=Np;var{AddressZero:U1}=yt,Dn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Oa(Dn.extensionType),e.address);if(t===U1)throw new Error(`${Dn.extensionType} extension is not installed for this Colony`);let n=await Mr(t,e.colonyNetwork.signerOrProvider);if(!Ba(Dn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Dn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Dn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Dn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Dn(e,r,n)}static getLatestSupportedVersion(){return Dn.supportedVersions[Dn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ea(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ea(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ie("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Oa(we.OneTxPayment),t],async n=>({...ie("ExtensionUpgraded",n)}))}},ja=Dn;ja.supportedVersions=[{version:3,factory:Oi},{version:4,factory:Bi},{version:5,factory:Fi}],ja.extensionType=we.OneTxPayment;var On=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ie("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ie("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ie("Approval",n)}))}};var Vs=class extends On{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Nn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ie("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ie("LogSetOwner",n)}))}};var js=class extends On{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ie("Approval",i)}))}};var Ph=async(a,e)=>{let t=await _p(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new Vs(a,t);case wn.Erc20:return new On(a,t);case wn.Erc2612:return new js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Li.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Ui.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Vi.abi=Bp;var{AddressZero:Fp}=yt;var Uu=F.from(10).pow(18),Bn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Oa(Bn.extensionType),e.address);if(t===Fp)throw new Error(`${Bn.extensionType} extension is not installed for this Colony`);let n=await Mr(t,e.colonyNetwork.signerOrProvider);if(!Ba(Bn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Bn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Bn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Bn(e,r,n)}static getLatestSupportedVersion(){return Bn.supportedVersions[Bn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ie("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Is(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Dl);return[e,t,Fp,Dl,n,i,r,s]},async t=>({...ie("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ie("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Lu("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ea(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ie("MotionStaked",r),...ie("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ie("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ie("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await wi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ie("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ie("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Oa(we.VotingReputation),t],async n=>({...ie("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ha=Bn;Ha.supportedVersions=[{version:7,factory:Li},{version:8,factory:Ui},{version:9,factory:Vi}],Ha.extensionType=we.VotingReputation;var q1={["motion"]:Ha,["oneTx"]:ja},Or=class{static async connect(e,t){let n=await Mr(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Ph(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new ta(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ha.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new On(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ie("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ie("DomainAdded",t),...ie("FundingPotAdded",t),...ie("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ie("DomainAdded",t),...ie("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ie("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ie("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ie("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ea(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await wi(x,this.colony,r,s),_=await wi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ie("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ie("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ie("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=q1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Ba(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Oa(i),t.getLatestSupportedVersion()],async s=>({...Lu("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return au(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ie("ColonyRoleSet",i),...ie("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ie("ColonyRoleSet",i),...ie("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ie("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ie("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ie("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ie("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ie("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ie("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ie("ArbitraryReputationUpdate",i)}))}},Hs=Or;Hs.supportedVersions=[{version:11,factory:Pi},{version:12,factory:Ni},{version:13,factory:Di}];var{splitSignature:xP}=te;var{namehash:LP}=te,{AddressZero:UP}=yt;var z1=new Zn.JsonRpcProvider(Es.Gnosis),{isAddress:W1}=te,K1=(a,e)=>{let t=new Va(z1),n=t.createEventSource(Ii),i=t.createMultiFilter(n,["DomainAdded(address,uint256)","DomainMetadata(address,uint256,string)"],a),r=0;t.provider.on("block",async s=>{if(r+=1,r===4){let o=await t.getMultiEvents(i,{fromBlock:s-r,toBlock:s});o.length&&e(o),r=0}})},Up=document.querySelector("#address"),Nh=document.querySelector("#button"),Vp=document.querySelector("#error"),Dh=document.querySelector("#result");if(!Up||!Nh||!Vp||!Dh)throw new Error("Could not find all required HTML elements");var J1=a=>{Vp.innerText=a},$1=()=>{Vp.innerText=""},Lp=a=>{Dh.innerText=a};Nh.addEventListener("click",async()=>{$1();let a=Up.value;return W1(a)?(Up.value="",K1(a,e=>{Lp(`A domain with id ${e[0].data.domainId} was created on Colony ${e[0].address}.`),e.forEach(async t=>{if(t.getMetadata){let n=await t.getMetadata();if(n.name===Re.Domain){let{domainName:i,domainColor:r,domainPurpose:s}=n.data;Lp(`A domain with id ${t.data.domainId} was created on Colony ${t.address}. It's name is ${i}, it's color ${r} and was created for the following purpose: ${s}`)}}})}),Lp(`Set up event listener for Colony ${a}`),null):J1("This is not a valid address")});})(); /** * [js-sha3]{@link https://github.com/emn178/js-sha3} * diff --git a/local-basic.js b/local-basic.js index 6ca172f44..869574312 100644 --- a/local-basic.js +++ b/local-basic.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),B5)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var F5="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ns=null;function lf(a){if(ns==null&&(ns=F5.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),xn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ns=null,new Error("BIP39 Wordlist for en (English) FAILED")}var el=class extends xn{constructor(){super("en")}getWord(e){return lf(this),ns[e]}getWordIndex(e){return lf(this),ns.indexOf(e)}},tl=new el;xn.register(tl);var hi={en:tl};var pf="hdnode/5.7.0";var as=new M(pf),L5=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),U5=ve("Bitcoin seed"),cr=2147483648;function ff(a){return(1<=256)throw new Error("Depth too large!");return yf(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,me(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new It(fr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~cr));let n=new Uint8Array(37);if(e&cr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(fa(Qn.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=Do(F.from(r).add(this.privateKey).mod(L5)):l=new mn(W(r))._addPoint(this.publicKey);let p=t,f=this.mnemonic;return f&&(p=Object.freeze({phrase:f.phrase,path:t,locale:f.locale||"en"})),new It(fr,o,l,this.fingerprint,Do(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=cr)throw new Error("invalid path index - "+r);n=n._derive(cr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=cr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(fa(Qn.sha512,U5,n));return new It(fr,Do(i.slice(0,32)),null,"0x00000000",Do(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=nl(n),e=xi(mr(e,n),n),It._fromSeed(al(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return It._fromSeed(e,null)}static fromExtendedKey(e){let t=ya.decode(e);(t.length!==82||yf(t.slice(0,78))!==e)&&as.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new It(fr,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new It(fr,W(o.slice(1)),null,i,s,r,n,null)}return as.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function al(a,e){e||(e="");let t=ve("mnemonic"+e,Gt.NFKD);return mi(ve(a,Gt.NFKD),t,2048,64,"sha512")}function mr(a,e){e=nl(e),as.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=ff(s);if((j(Xt(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function xi(a,e){if(e=nl(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&V5(8-n)),n+=3);let i=a.length/4,r=j(Xt(a))[0]&ff(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function cf(a,e){try{return mr(a,e),!0}catch{}return!1}function mf(a){return(typeof a!="number"||a<0||a>=cr||a%1)&&as.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var hf="random/5.7.0";var il=new M(hf);function j5(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var xf=j5(),Oo=xf.crypto||xf.msCrypto;(!Oo||!Oo.getRandomValues)&&(il.warn("WARNING: Missing strong random number source"),Oo={getRandomValues:function(a){return il.throwError("no secure random source avaialble",M.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Xn(a){(a<=0||a>1024||a%1||a!=a)&&il.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Oo.getRandomValues(e),j(e)}function is(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var ol=kn(sl());var Bo="json-wallets/5.7.0";function ma(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function hr(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),E=new ha.default.Counter(x),J=new ha.default.ModeOfOperation.ctr(O,E),$=j(J.encrypt(i)),de=fe(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:gf(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(f).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=Xn(16),N=new ha.default.Counter(R),q=new ha.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+hr(I.getUTCMonth()+1,2)+"-"+hr(I.getUTCDate(),2)+"T"+hr(I.getUTCHours(),2)+"-"+hr(I.getUTCMinutes(),2)+"-"+hr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function If(a,e,t){if(Fo(a)){t&&t(0);let n=dl(a,e);return t&&t(1),Promise.resolve(n)}return Lo(a)?Ef(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function Cf(a,e){if(Fo(a))return dl(a,e);if(Lo(a))return Mf(a,e);throw new Error("invalid JSON wallet")}var Sf="wallet/5.7.0";var Rf=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},xr=new M(Sf);function W5(a){return a!=null&&ie(a.privateKey,32)&&a.address!=null}function K5(a){let e=a.mnemonic;return e&&e.phrase}var on=class extends St{constructor(e,t){if(super(),W5(e)){let n=new mn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",hn(this.publicKey)),this.address!==ce(e.address)&&xr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),K5(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||ca,locale:i.locale||"en"}));let r=this.mnemonic,s=It.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);hn(s.privateKey)!==this.address&&xr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(mn.isSigningKey(e))e.curve!=="secp256k1"&&xr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new mn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",hn(this.publicKey))}t&&!$t.isProvider(t)&&xr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new on(this,e)}signTransaction(e){return Ce(e).then(t=>{t.from!=null&&(ce(t.from)!==this.address&&xr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(fe(Zr(t)));return Zr(t,n)})}signMessage(e){return Rf(this,void 0,void 0,function*(){return Fr(this._signingKey().signDigest(er(e)))})}_signTypedData(e,t,n){return Rf(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,r=>(this.provider==null&&xr.throwError("cannot resolve ENS names without a provider",M.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return Fr(this._signingKey().signDigest(bt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),cl(this,e,t,n)}static createRandom(e){let t=Xn(16);e||(e={}),e.extraEntropy&&(t=j(Ie(fe(ye([t,e.extraEntropy])),0,16)));let n=xi(t,e.locale);return on.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return If(e,t,n).then(i=>new on(i))}static fromEncryptedJsonSync(e,t){return new on(Cf(e,t))}static fromMnemonic(e,t,n){return t||(t=ca),new on(It.fromMnemonic(e,null,n).derivePath(t))}};function Pf(a,e){return yi(er(a),e)}function Nf(a,e,t,n){return yi(bt.hash(a,e,t),n)}var ea={};Hi(ea,{AlchemyProvider:()=>_r,AlchemyWebSocketProvider:()=>hs,AnkrProvider:()=>xs,BaseProvider:()=>Zn,CloudflareProvider:()=>bs,EtherscanProvider:()=>gs,FallbackProvider:()=>vs,Formatter:()=>Y,InfuraProvider:()=>Ar,InfuraWebSocketProvider:()=>_s,IpcProvider:()=>El,JsonRpcBatchProvider:()=>eu,JsonRpcProvider:()=>Yt,JsonRpcSigner:()=>vr,NodesmithProvider:()=>ks,PocketProvider:()=>As,Provider:()=>$t,Resolver:()=>Tr,StaticJsonRpcProvider:()=>ms,UrlJsonRpcProvider:()=>Ct,Web3Provider:()=>Ms,WebSocketProvider:()=>ga,getDefaultProvider:()=>tu,getNetwork:()=>ss,isCommunityResourcable:()=>xl,isCommunityResource:()=>ds,showThrottleMessage:()=>Yn});var Df="networks/5.7.1";var Of=new M(Df);function J5(a){return a&&typeof a.renetwork=="function"}function xa(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return xa(t)},e}function jo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return jo(a,n)},t}var Bf={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:xa("homestead")},Ff={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:xa("ropsten")},Lf={chainId:63,name:"classicMordor",_defaultProvider:jo("https://www.ethercluster.com/mordor","classicMordor")},Vo={unspecified:{chainId:0,name:"unspecified"},homestead:Bf,mainnet:Bf,morden:{chainId:2,name:"morden"},ropsten:Ff,testnet:Ff,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:xa("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:xa("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:xa("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:xa("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:jo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Lf,classicTestnet:Lf,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:jo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:xa("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:xa("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ss(a){if(a==null)return null;if(typeof a=="number"){for(let n in Vo){let i=Vo[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=Vo[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=Vo[a.name];if(!e)return typeof a.chainId!="number"&&Of.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&Of.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(J5(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Uf="web/5.7.1";var $5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Vf(a,e){return $5(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var Q5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Sn=new M(Uf);function jf(a){return new Promise(e=>{setTimeout(e,a)})}function Da(a,e){if(a==null)return null;if(typeof a=="string")return a;if(aa(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Jt(a)}catch{}return W(a)}return a}function X5(a){return ve(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function ml(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Sn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Sn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},f=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Sn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(f=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Sn.throwError("basic authentication requires a secure https url",M.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+Zi(ve(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?Yi(_[3]):X5(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Sn.throwError("processing response error",M.errors.SERVER_ERROR,{body:Da(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(E,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Sn.makeError("timeout",M.errors.TIMEOUT,{requestBody:Da(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return Q5(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Sn.throwError("bad response",M.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Da(H,U.headers?U.headers["content-type"]:null),requestBody:Da(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let E=yield t(H,U);return S.cancel(),E}catch(E){if(E.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Jt(r))}catch(l){Sn.throwError("invalid JSON",M.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=ve(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return ml(a,i,n)}function Pn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(f){if(f!==void 0)s()&&t(f);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(f){s()&&n(f)})}p()})}var vl=kn(zf());var Ae="providers/5.7.2";var us=new M(Ae),Y=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),f=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:Y.allowNull(this.accessList.bind(this),null),blockHash:Y.allowNull(s,null),blockNumber:Y.allowNull(l,null),transactionIndex:Y.allowNull(l,null),confirmations:Y.allowNull(l,null),from:t,gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),gasLimit:n,to:Y.allowNull(t,null),value:n,nonce:l,data:r,r:Y.allowNull(this.uint256),s:Y.allowNull(this.uint256),v:Y.allowNull(l),creates:Y.allowNull(t,null),raw:Y.allowNull(r)},e.transactionRequest={from:Y.allowNull(t),nonce:Y.allowNull(l),gasLimit:Y.allowNull(n),gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),to:Y.allowNull(t),value:Y.allowNull(n),data:Y.allowNull(f),type:Y.allowNull(l),accessList:Y.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:Y.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:Y.allowNull(this.address,null),from:Y.allowNull(this.address,null),contractAddress:Y.allowNull(t,null),transactionIndex:l,root:Y.allowNull(o),gasUsed:n,logsBloom:Y.allowNull(r),blockHash:s,transactionHash:s,logs:Y.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:Y.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:Y.allowNull(n),status:Y.allowNull(l),type:p},e.block={hash:Y.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:Y.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:Y.allowNull(t),extraData:r,transactions:Y.allowNull(Y.arrayOf(s)),baseFeePerGas:Y.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=Y.allowNull(Y.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:Y.allowNull(i,void 0),toBlock:Y.allowNull(i,void 0),blockHash:Y.allowNull(s,void 0),address:Y.allowNull(t,void 0),topics:Y.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:Y.allowNull(l),blockHash:Y.allowNull(s),transactionIndex:l,removed:Y.allowNull(this.boolean.bind(this)),address:t,data:Y.allowFalsish(r,"0x"),topics:Y.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return sn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():us.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ce(e)}callAddress(e){if(!ie(e,32))return null;let t=ce(Ie(e,12));return t===ro?null:t}contractAddress(e){return ui(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return Ln(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Nt(n)!==32?us.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return me(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=Y.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return Y.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=Y.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ie(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ie(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return Io(e)}receiptLog(e){return Y.check(this.formats.receiptLog,e)}receipt(e){let t=Y.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&us.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):us.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&us.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return Y.check(this.formats.filter,e)}filterLog(e){return Y.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function xl(a){return a&&typeof a.isCommunityResource=="function"}function ds(a){return xl(a)&&a.isCommunityResource()}var Wf=!1;function Yn(){Wf||(Wf=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},he=new M(Ae),rx=10;function Kf(a){return a==null?"null":(Nt(a)!==32&&he.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function Jf(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[Kf(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return Kf(e)}).join("&")}function sx(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function gr(a){if(typeof a=="string"){if(a=a.toLowerCase(),Nt(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+Jf(a);if(xo.isForkEvent(a))throw he.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+Jf(a.topics||[])}throw new Error("invalid event - "+a)}function ls(){return new Date().getTime()}function $f(a){return new Promise(e=>{setTimeout(e,a)})}var ox=["block","network","pending","poll"],wl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=sx(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||ox.indexOf(this.tag)>=0}},ux={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function bl(a){return me(F.from(a).toHexString(),32)}function Qf(a){return ya.encode(ye([a,Ie(Xt(Xt(a)),0,4)]))}var Zf=new RegExp("^(ipfs)://(.*)$","i"),Xf=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Zf,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function zo(a,e){try{return Jt(ps(a,e))}catch{}return null}function ps(a,e){if(a==="0x")return null;let t=F.from(Ie(a,e,e+32)).toNumber(),n=F.from(Ie(a,t,t+32)).toNumber();return Ie(a,t+32,t+32+n)}function gl(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):he.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function Yf(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function dx(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function ec(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===M.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:kt([e,Ia(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=kt(["0x9061b923",ec([$r(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&he.throwError("resolver threw error",M.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=ps(r,0)),r}catch(r){if(r.code===M.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?ps(n,0):null})}_getAddress(e,t){let n=ux[String(e)];if(n==null&&he.throwError(`unsupported coin type: ${e}`,M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return Qf(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return Qf(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=vl.default.toWords(i.slice(2));return o.unshift(s),vl.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===Qi?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===M.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",bl(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&he.throwError("invalid or unsupported coin data",M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return he.throwError("invalid or unsupported content hash data",M.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=ve(e);t=ye([bl(64),bl(t.length),t]),t.length%32!==0&&(t=ye([t,me("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Jt(n)})}},Tl=null,lx=1,Zn=class extends $t{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=mt(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):he.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||he.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Pn(()=>this._ready().then(e=>e,e=>{if(!(e.code===M.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return Tl==null&&(Tl=new Y),Tl}static getNetwork(e){return ss(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Rn({url:p,errorPassThrough:!0},f,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return he.throwError(`response not found during CCIP fetch: ${C}`,M.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return he.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,M.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(ls()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=ls(),n=Ce({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=ls();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=lx++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)he.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",he.makeError("network block skew detected",M.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return he.throwError("provider does not support network detection",M.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield $f(0),this._network;let n=he.makeError("underlying network changed",M.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=ls();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,f=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield $f(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{f()||o(he.makeError("timeout exceeded",M.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Ln(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Nt(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&he.throwError("Transaction hash mismatch from Provider.sendTransaction.",M.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&he.throwError("transaction failed",M.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Ce(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Ce(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=rx&&he.throwError("CCIP read exceeded maximum redirections",M.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Nt(r)%32===4)try{let s=Ie(r,4),o=Ie(s,0,32);F.from(o).eq(i)||he.throwError("CCIP Read sender did not match",M.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ie(s,32,64)).toNumber(),f=F.from(Ie(s,p,p+32)).toNumber(),x=Ie(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Ce({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),Y.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&he.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new Tr(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||he.throwError("network does not support ENS",M.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Ia(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ie(e))throw n}typeof e!="string"&&he.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=zo(yield this.call({to:n,data:"0x691f3431"+Ia(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new Tr(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o}try{let o=zo(yield this.call({to:s,data:"0x691f3431"+Ia(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return he.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new wl(gr(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=gr(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=gr(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=gr(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=gr(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=gr(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var ba=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Mt=new M(Ae),px=["call","estimateGas"];function fs(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ie(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=fs(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return fs(JSON.parse(a),e)}catch{}return null}function nc(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=fs(e,!0);if(r)return r.data;Mt.throwError("missing revert data in call exception; Transaction reverted without a reason string",M.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=fs(e.body,!1);r==null&&(r=fs(e,!1)),r&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===M.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Mt.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Mt.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Mt.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Mt.throwError("legacy pre-eip-155 transactions not supported",M.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),px.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function tc(a){return new Promise(function(e){setTimeout(e,a)})}function yx(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function ys(a){return a&&a.toLowerCase()}var _l={},vr=class extends St{constructor(e,t,n){if(super(),e!==_l)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Mt.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Mt.throwError("cannot alter JSON-RPC Signer connection",M.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new kl(_l,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Mt.throwError("unknown account #"+this._index,M.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>ba(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Mt.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Ce({tx:Ce(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Mt.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected transaction",M.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),nc("sendTransaction",s,r)))})}signTransaction(e){return Mt.throwError("signing transactions is unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return ba(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Pn(()=>ba(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return ba(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return ba(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return ba(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(bt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return ba(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},kl=class extends vr{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},fx={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},Yt=class extends Zn{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=mt(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return ba(this,void 0,void 0,function*(){yield tc(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=mt(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new vr(_l,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:ct(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Rn(this.connection,JSON.stringify(n),yx).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ys(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ys(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ys(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ys(t.address),me(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=ys(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return ba(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Mt.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return nc(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return tc(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(fx);if(t)for(let r in t)t[r]&&(n[r]=!0);zi(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Ln(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=sn(e.accessList)),i}};var wr=null;try{if(wr=WebSocket,wr==null)throw new Error("inject please")}catch{let e=new M(Ae);wr=function(){e.throwError("WebSockets not supported in this environment",M.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var Al=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Wo=new M(Ae),cx=1,ga=class extends Yt{constructor(e,t){t==="any"&&Wo.throwError("WebSocketProvider does not support 'any' network yet",M.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new wr(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){Wo.throwError("cannot reset events block on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){Wo.throwError("cannot set polling interval on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return Al(this,void 0,void 0,function*(){return null})}set polling(e){!e||Wo.throwError("cannot set polling on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=cx++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return Al(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return Al(this,void 0,void 0,function*(){this.websocket.readyState===wr.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var mx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},cs=new M(Ae),ms=class extends Yt{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return mx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||cs.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Ct=class extends ms{constructor(e,t){cs.checkAbstract(new.target,Ct),e=mt(new.target,"getNetwork")(e),t=mt(new.target,"getApiKey")(t);let n=mt(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){cs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return cs.throwError("API provider does not support signing",M.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return cs.throwError("not implemented; sub-classes must override getUrl",M.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var ac=new M(Ae),Ko="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",hs=class extends ga{constructor(e,t){let n=new _r(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===Ko}},_r=class extends Ct{static getWebSocketProvider(e,t){return new hs(e,t)}static getApiKey(e){return e==null?Ko:(e&&typeof e!="string"&&ac.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:ac.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===Ko&&Yn(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===Ko}};var hx=new M(Ae),Jo="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function xx(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return hx.throwArgumentError("unsupported network","name",a)}var xs=class extends Ct{isCommunityResource(){return this.apiKey===Jo}static getApiKey(e){return e??Jo}static getUrl(e,t){t==null&&(t=Jo);let n={allowGzip:!0,url:"https://"+xx(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===Jo&&Yn(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var bx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},ic=new M(Ae),bs=class extends Ct{static getApiKey(e){return e!=null&&ic.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:ic.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return bx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var $o=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Oa=new M(Ae);function rc(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Ln(W(n)):t==="accessList"?n="["+sn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function gx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function sc(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function oc(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function Ml(a,e,t){if(a==="call"&&e.code===M.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Oa.throwError("missing revert data in call exception",M.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===M.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Oa.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Oa.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Oa.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Oa.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var gs=class extends Zn{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Oa.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return $o(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?sc:gx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(f,x)=>(this.isCommunityResource()&&Yn(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(f=>`${f}=${r[f]}`).join("&"));let p=yield Rn(o,l,s||sc);return this.emit("debug",{action:"response",request:i,response:ct(p),provider:this}),p})}detectNetwork(){return $o(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return $o(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Ml("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=rc(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Ml("call",r,t.transaction)}}case"estimateGas":{let i=rc(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Ml("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=oc(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=oc(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Oa.throwError("unsupported topic count",M.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Oa.throwError("unsupported topic format",M.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var Yo=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},bi=new M(Ae);function Qo(){return new Date().getTime()}function uc(a){let e=null;for(let t=0;te?null:(n+i)/2}function kr(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>kr(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=kr(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var Tx=1;function lc(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var vx=[M.errors.CALL_EXCEPTION,M.errors.INSUFFICIENT_FUNDS,M.errors.NONCE_EXPIRED,M.errors.REPLACEMENT_UNDERPRICED,M.errors.UNPREDICTABLE_GAS_LIMIT],wx=["address","args","errorArgs","errorSignature","method","transaction"];function Xo(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function _x(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function kx(a,e,t){let n=kr;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=dc(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return dc(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,kr(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),kr(i))}:n=function(i){return i==null?null:kr(i)};break;default:throw new Error("unknown method: "+e)}return _x(n,a.quorum)}function Ts(a,e){return Yo(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Pn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function Ax(a,e,t,n){return Yo(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield Ts(a,e)),i.getLogs(r)}}return bi.throwError("unknown method error",M.errors.UNKNOWN_ERROR,{method:t,params:n})})}var vs=class extends Zn{constructor(e,t){e.length===0&&bi.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if($t.isProvider(s)){let f=ds(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:f,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=ds(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&bi.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&bi.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=uc(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return Yo(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return uc(e)})}perform(e,t){return Yo(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(f=>f.hash,f=>f)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=Qo(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=Ax(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Xo(_,Qo()),request:{method:e,params:ct(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Xo(_,Qo()),request:{method:e,params:ct(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Xo(_,null),request:{method:e,params:ct(t)},provider:this}),p+=_.weight}let f=[];i.forEach(_=>{_.done||!_.runner||(f.push(_.runner),_.staller&&f.push(_.staller.getPromise()))}),f.length&&(yield Promise.race(f));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield lc(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return vx.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};wx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),bi.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),bi.throwError("failed to meet quorum",M.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>Xo(l)),provider:this})})}};var El=null;var Zo=new M(Ae),ws="84842078b09946638c03157f83405213",_s=class extends ga{constructor(e,t){let n=new Ar(e,t),i=n.connection;i.password&&Zo.throwError("INFURA WebSocket project secrets unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===ws}},Ar=class extends Ct{static getWebSocketProvider(e,t){return new _s(e,t)}static getApiKey(e){let t={apiKey:ws,projectId:ws,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(Zo.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),Zo.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:Zo.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===ws&&Yn(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===ws}};var eu=class extends Yt{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:ct(o),provider:this}),Rn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,f)=>{let x=l[f];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Il=new M(Ae),Mx="ETHERS_JS_SHARED",ks=class extends Ct{static getApiKey(e){return e&&typeof e!="string"&&Il.throwArgumentError("invalid apiKey","apiKey",e),e||Mx}static getUrl(e,t){Il.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Il.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var pc=new M(Ae),yc="62e1ad51b37b8e00394bda3b",As=class extends Ct{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=yc:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:pc.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:pc.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===yc}};var fc=new M(Ae),Ex=1;function cc(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:Ex++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:ct(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let f=new Error(p.error.message);return f.code=p.error.code,f.data=p.error.data,o(f)}s(p.result)})})}}function Ix(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:ct(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var Ms=class extends Yt{constructor(e,t){e==null&&fc.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Ix(e)):e.sendAsync?i=cc(e,e.sendAsync.bind(e)):e.send?i=cc(e,e.send.bind(e)):fc.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var mc=new M(Ae);function tu(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new Yt(a);case"ws":case"wss":return new ga(a);default:mc.throwArgumentError("unsupported URL scheme","network",a)}}let t=ss(a);return(!t||!t._defaultProvider)&&mc.throwError("unsupported getDefaultProvider network",M.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:vs,AlchemyProvider:_r,AnkrProvider:xs,CloudflareProvider:bs,EtherscanProvider:gs,InfuraProvider:Ar,JsonRpcProvider:Yt,NodesmithProvider:ks,PocketProvider:As,Web3Provider:Ms,IpcProvider:null},e)}var te={};Hi(te,{AbiCoder:()=>Xi,ConstructorFragment:()=>Dt,ErrorFragment:()=>tn,EventFragment:()=>Ht,FormatTypes:()=>ge,Fragment:()=>qt,FunctionFragment:()=>Ot,HDNode:()=>It,Indexed:()=>oa,Interface:()=>Ca,LogDescription:()=>tr,Logger:()=>M,ParamType:()=>pt,RLP:()=>Xs,SigningKey:()=>mn,SupportedAlgorithm:()=>Qn,TransactionDescription:()=>nr,TransactionTypes:()=>Eo,UnicodeNormalizationForm:()=>Gt,Utf8ErrorFuncs:()=>po,Utf8ErrorReason:()=>Bt,_TypedDataEncoder:()=>bt,_fetchData:()=>ml,_toEscapedUtf8String:()=>Td,accessListify:()=>sn,arrayify:()=>j,base58:()=>ya,base64:()=>Md,checkProperties:()=>zi,checkResultErrors:()=>Ki,commify:()=>_c,computeAddress:()=>hn,computeHmac:()=>fa,computePublicKey:()=>Yr,concat:()=>ye,deepCopy:()=>ct,defaultAbiCoder:()=>Kr,defaultPath:()=>ca,defineReadOnly:()=>B,dnsEncode:()=>$r,entropyToMnemonic:()=>xi,fetchJson:()=>Rn,formatBytes32String:()=>vd,formatEther:()=>kc,formatUnits:()=>Cl,getAccountPath:()=>mf,getAddress:()=>ce,getContractAddress:()=>ui,getCreate2Address:()=>Iy,getIcapAddress:()=>Ey,getJsonWalletAddress:()=>ll,getStatic:()=>mt,hashMessage:()=>er,hexConcat:()=>kt,hexDataLength:()=>Nt,hexDataSlice:()=>Ie,hexStripZeros:()=>dd,hexValue:()=>Ln,hexZeroPad:()=>me,hexlify:()=>W,id:()=>nn,isAddress:()=>My,isBytes:()=>un,isBytesLike:()=>aa,isHexString:()=>ie,isValidMnemonic:()=>cf,isValidName:()=>Id,joinSignature:()=>Fr,keccak256:()=>fe,mnemonicToEntropy:()=>mr,mnemonicToSeed:()=>al,namehash:()=>Ia,nameprep:()=>Ad,parseBytes32String:()=>wd,parseEther:()=>Ac,parseTransaction:()=>Io,parseUnits:()=>Sl,poll:()=>Pn,randomBytes:()=>Xn,recoverAddress:()=>yi,recoverPublicKey:()=>Mo,resolveProperties:()=>Ce,ripemd160:()=>ts,serializeTransaction:()=>Zr,sha256:()=>Xt,sha512:()=>Zd,shallowCopy:()=>_e,shuffled:()=>is,solidityKeccak256:()=>bc,solidityPack:()=>nu,soliditySha256:()=>gc,splitSignature:()=>Un,stripZeros:()=>Zt,toUtf8Bytes:()=>ve,toUtf8CodePoints:()=>Ea,toUtf8String:()=>Jt,verifyMessage:()=>Pf,verifyTypedData:()=>Nf,zeroPad:()=>ii});var hc="solidity/5.7.0";var Cx=new RegExp("^bytes([0-9]+)$"),Sx=new RegExp("^(u?int)([0-9]*)$"),Rx=new RegExp("^(.*)\\[([0-9]*)\\]$"),Px="0000000000000000000000000000000000000000000000000000000000000000",Mr=new M(hc);function xc(a,e,t){switch(a){case"address":return t?ii(e,32):j(e);case"string":return ve(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?ii(e,32):j(e)}let n=a.match(Sx);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Mr.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),ii(e,i/8)}if(n=a.match(Cx),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Mr.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Mr.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+Px).substring(0,66)):e}if(n=a.match(Rx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Mr.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(xc(i,o,!0))}),ye(s)}return Mr.throwArgumentError("invalid type","type",a)}function nu(a,e){a.length!=e.length&&Mr.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(xc(n,e[i]))}),W(ye(t))}function bc(a,e){return fe(nu(a,e))}function gc(a,e){return Xt(nu(a,e))}var Tc="units/5.7.0";var vc=new M(Tc),wc=["wei","kwei","mwei","gwei","szabo","finney","ether"];function _c(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&vc.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Cl(a,e){if(typeof e=="string"){let t=wc.indexOf(e);t!==-1&&(e=3*t)}return Gi(a,e??18)}function Sl(a,e){if(typeof a!="string"&&vc.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=wc.indexOf(e);t!==-1&&(e=3*t)}return ln(a,e??18)}function kc(a){return Cl(a,18)}function Ac(a){return Sl(a,18)}var au="ethers/5.7.2";var Mc=new M(au);try{let a=window;a._ethers==null&&(a._ethers=Rl)}catch{}var Nn;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(Nn||(Nn={}));var iu;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(iu||(iu={}));var Er;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Er||(Er={}));var ru;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(ru||(ru={}));var Pl;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Pl||(Pl={}));var Es;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Es||(Es={}));var Is;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Is||(Is={}));var Nl;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(Nl||(Nl={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var zt;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(zt||(zt={}));var Ol="0x12345678",Dl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(Dl||(Dl={}));var vt;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(vt||(vt={}));var we;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(we||(we={}));var Bl=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],gi=class{static createInterface(){return new te.Interface(Bl)}static connect(e,t){return new oe(e,Bl,t)}};xe(gi,"abi",Bl);var Fl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],Ti=class{static createInterface(){return new te.Interface(Fl)}static connect(e,t){return new oe(e,Fl,t)}};xe(Ti,"abi",Fl);var Ec=(a,e)=>{throw new Error(`${e}: ${a}`)},Ll=a=>a!=null;var{keccak256:Dx,toUtf8Bytes:Ox}=te,{MaxUint256:Bx}=ht;var Ul=a=>te.formatEther(a);var Vl=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(vt.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(Ll)},vi=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return Bx;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},Ba=a=>Dx(Ox(a));var Ir=async(a,e)=>(await Ti.connect(a,e).version()).toNumber(),jl=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(Ll);var{hexDataSlice:Hl}=te,{MaxUint256:Fx}=ht,Ic=a=>{let e=Hl(a,0,3),t=F.from(Hl(a,4,35)),n=F.from(Hl(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Cc=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),Fx,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await vi(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},Lx=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Cc(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?ta(a,e,t,n[0],i):Lx(a,e,t,n,i):Cc(a,e,t,n,i);var{MaxUint256:Sc}=ht,{AddressZero:Ux}=ht;async function Vx(a,e){let t;try{return t=await a.getCapabilityRoles(te.hexZeroPad(e,4)),su(t)}catch{return[]}}async function Cs(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:f,childSkillIndex:x}=Ic(s),C=gi.connect(r,n.signer||n.provider),_=await Vx(C,p);if(_.includes(vt.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Sc}else{let{skillId:U}=await e.getDomain(f),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Sc;else{let{children:E}=await a.getSkill(l),J=E.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,Ux);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:jx}=ht,na=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||Nn.Gnosis;this.endpointUrl=n?.customEndpointUrl||Er[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await na.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await na.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await na.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let f=p+1,x=await this.colony.getDomain(f);return{domainId:f,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,f=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return f&&(p=f?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return na.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${jx}/noProof`,s=await na.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var _t=a=>Array.from(Array(a-1)).map(e=>e+1);var Rc=10,Dk=_t(Rc),Pc={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},Nc=Rc-1;var Dc=6,Fk=_t(Dc),Oc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},Bc=Dc-1;var Fc=7,Vk=_t(Fc),Lc={1:[],2:[],3:[],4:[],5:[],6:[]},Uc=Fc-1;var Vc=7,qk=_t(Vc),jc={1:[],2:[],3:[],4:[],5:[],6:[]},Hc=Vc-1;var qc=4,Wk=_t(qc),Gc={1:[],2:[],3:[]},zc=qc-1;var Wc=5,$k=_t(Wc),Kc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},Jc=Wc-1;var $c=2,Yk=_t($c),Qc={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},Xc=$c-1;var Yc=4,tA=_t(Yc),Zc={1:[1,2,3],2:[1,2,3],3:[1,2,3]},em=Yc-1;var tm=7,iA=_t(tm),nm={1:[],2:[],3:[],4:[],5:[],6:[]},am=tm-1;var im=11,oA=_t(im),ql={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Gl=im-1;var rm=6,lA=_t(rm),sm={1:[],2:[],3:[],4:[],5:[]},om=rm-1;var Fa=(a,e,t)=>{switch(a){case we.CoinMachine:{let n=Pc[e];return!!n&&!n.includes(t)}case we.EvaluatedExpenditure:{let n=Oc[e];return!!n&&!n.includes(t)}case we.FundingQueue:{let n=Lc[e];return!!n&&!n.includes(t)}case we.IVotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.OneTxPayment:{let n=jc[e];return!!n&&!n.includes(t)}case we.ReputationBootstrapper:{let n=Gc[e];return!!n&&!n.includes(t)}case we.StagedExpenditure:{let n=Qc[e];return!!n&&!n.includes(t)}case we.StakedExpenditure:{let n=Kc[e];return!!n&&!n.includes(t)}case we.StreamingPayments:{let n=Zc[e];return!!n&&!n.includes(t)}case we.TokenSupplier:{let n=nm[e];return!!n&&!n.includes(t)}case we.VotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.Whitelist:{let n=sm[e];return!!n&&!n.includes(t)}default:return Ec(a,"Could not find extension with name")}};var Hx={[we.CoinMachine]:Nc,[we.EvaluatedExpenditure]:Bc,[we.FundingQueue]:Uc,[we.IVotingReputation]:Gl,[we.OneTxPayment]:Hc,[we.ReputationBootstrapper]:zc,[we.StagedExpenditure]:Xc,[we.StakedExpenditure]:Jc,[we.StreamingPayments]:em,[we.TokenSupplier]:am,[we.VotingReputation]:Gl,[we.Whitelist]:om};var Ch=kn(um(),1);var yp=kn(Mh(),1);var Re;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Re||(Re={}));var pp=2,lp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(lp||(lp={}));var Eh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,t1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Eh(t.errors);throw new Error(n)};var Ih=(a,e)=>{let t=a===Re.Colony?t1(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:pp});if(!n.success){let i=Eh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ch.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Fs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Nr=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Fs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Fs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Ih(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var FM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],vn=class{static createInterface(){return new te.Interface(xp)}static connect(e,t){return new oe(e,xp,t)}};xe(vn,"abi",xp);var bp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],wn=class{static createInterface(){return new te.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(wn,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ei=class{static createInterface(){return new te.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Ei,"abi",gp);var Vu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Sh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",k1=a=>a.length>1,Dn=class extends ci{constructor(...e){k1(e)?super(...e):super(Vu,Sh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Vu)}static connect(e,t){return new oe(e,Vu,t)}};xe(Dn,"bytecode",Sh),xe(Dn,"abi",Vu);var Tp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new te.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(Ii,"abi",Tp);var vp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ci=class{static createInterface(){return new te.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Si;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Si||(Si={}));var _n;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(_n||(_n={}));var{AddressZero:Rh}=ht;async function E1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var I1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await E1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Rh)}catch{i=!1}try{await t.nonces(Rh)}catch{r=!1}return n?i?t.tokenClientType=_n.Colony:(t=Ii.connect(a,e),t.tokenClientType=_n.ColonyLegacy):r?(t=wn.connect(a,e),t.tokenClientType=_n.Erc2612):(t=vn.connect(a,e),t.tokenClientType=_n.Erc20),t.clientType=Si.TokenClient,t},wp=I1;var C1=(a,e)=>{let t=Ci.connect(a,e);return t.clientType=Si.TokenLockingClient,t},_p=C1;var{AddressZero:kp}=ht,S1=vn.connect(kp,new ea.BaseProvider(3656691)).interface,R1=Ei.connect(kp,new ea.BaseProvider(3656691)).interface,P1=wn.connect(kp,new ea.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ls=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Ls.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Us=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};Us.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Ri.abi=Ep;var Ta=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Fs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:D1,solidityKeccak256:O1,splitSignature:B1}=te,Pi=class extends Ta{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=O1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=D1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=B1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Ni.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Di.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Oi.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Bi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Fi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Li.abi=Np;var{AddressZero:q1}=ht,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(On.extensionType),e.address);if(t===q1)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},Va=On;Va.supportedVersions=[{version:3,factory:Bi},{version:4,factory:Fi},{version:5,factory:Li}],Va.extensionType=we.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=vn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var Vs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var js=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=wn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Ph=async(a,e)=>{let t=await wp(e,a.signerOrProvider);switch(t.tokenClientType){case _n.Colony:return new Vs(a,t);case _n.Erc20:return new Bn(a,t);case _n.Erc2612:return new js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Ui.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Vi.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};ji.abi=Bp;var{AddressZero:Fp}=ht;var Hu=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(Fn.extensionType),e.address);if(t===Fp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Cs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Ol);return[e,t,Fp,Ol,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await vi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},ja=Fn;ja.supportedVersions=[{version:7,factory:Ui},{version:8,factory:Vi},{version:9,factory:ji}],ja.extensionType=we.VotingReputation;var K1={["motion"]:ja,["oneTx"]:Va},Or=class{static async connect(e,t){let n=await Ir(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Ph(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new na(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Va.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ta(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await vi(x,this.colony,r,s),_=await vi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=K1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Fa(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Ba(i),t.getLatestSupportedVersion()],async s=>({...ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return su(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Br=Or;Br.supportedVersions=[{version:11,factory:Ni},{version:12,factory:Di},{version:13,factory:Oi}];var{splitSignature:J1}=te,qu=class extends Ta{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=J1(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Hs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=_p(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Nh}=te,{AddressZero:Lp}=ht,qs=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Nr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||ru[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Er[this.network]},this.networkContract=Ri.connect(t?.customNetworkAddress||iu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Hs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new Ta({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Pi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Lp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Br.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Es[this.network],""):null}async getColonyAddress(e){let t=Nh(`${e}${Es[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Is[this.network],""):null}async getUserAddress(e){let t=Nh(`${e}${Is[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{formatEther:$1,isAddress:Q1}=te,X1=new ea.JsonRpcProvider("http://127.0.0.1:8545"),Y1=()=>new on("0x0355596cdb5e5242ad082c4fe3f8bbe48c9dba843fe1f99dd8272f487e70efae",X1),Z1=async a=>{let e=Y1(),i=await(await new qs(e,{customNetworkAddress:a,reputationOracleEndpoint:"http://localhost:3000"}).getMetaColony()).getBalance();return $1(i)},Vp=document.querySelector("#address"),Oh=document.querySelector("#button"),jp=document.querySelector("#error"),Bh=document.querySelector("#result");if(!Vp||!Oh||!jp||!Bh)throw new Error("Could not find all required HTML elements");var Dh=a=>{jp.innerText=a},eg=()=>{jp.innerText=""},Up=a=>{Bh.innerText=a};Oh.addEventListener("click",async()=>{eg();let a=Vp.value;if(!Q1(a))return Dh("This is not a valid address");Up("Thinking..."),Vp.value="";let e;try{e=await Z1(a),Up(`${e} CLNY in root domain of local MetaColony`)}catch(t){Dh(`Found an error: ${t.message}`),Up("")}return null});})(); +`)}`,t1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Eh(t.errors);throw new Error(n)};var Ih=(a,e)=>{let t=a===Re.Colony?t1(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:pp});if(!n.success){let i=Eh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ch.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Fs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Nr=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Fs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Fs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Ih(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var FM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],vn=class{static createInterface(){return new te.Interface(xp)}static connect(e,t){return new oe(e,xp,t)}};xe(vn,"abi",xp);var bp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],wn=class{static createInterface(){return new te.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(wn,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ei=class{static createInterface(){return new te.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Ei,"abi",gp);var Vu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Sh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",k1=a=>a.length>1,Dn=class extends ci{constructor(...e){k1(e)?super(...e):super(Vu,Sh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Vu)}static connect(e,t){return new oe(e,Vu,t)}};xe(Dn,"bytecode",Sh),xe(Dn,"abi",Vu);var Tp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new te.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(Ii,"abi",Tp);var vp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ci=class{static createInterface(){return new te.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Si;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Si||(Si={}));var _n;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(_n||(_n={}));var{AddressZero:Rh}=ht;async function E1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var I1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await E1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Rh)}catch{i=!1}try{await t.nonces(Rh)}catch{r=!1}return n?i?t.tokenClientType=_n.Colony:(t=Ii.connect(a,e),t.tokenClientType=_n.ColonyLegacy):r?(t=wn.connect(a,e),t.tokenClientType=_n.Erc2612):(t=vn.connect(a,e),t.tokenClientType=_n.Erc20),t.clientType=Si.TokenClient,t},wp=I1;var C1=(a,e)=>{let t=Ci.connect(a,e);return t.clientType=Si.TokenLockingClient,t},_p=C1;var{AddressZero:kp}=ht,S1=vn.connect(kp,new ea.BaseProvider(3656691)).interface,R1=Ei.connect(kp,new ea.BaseProvider(3656691)).interface,P1=wn.connect(kp,new ea.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ls=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Ls.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Us=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};Us.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Ri.abi=Ep;var Ta=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Fs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:D1,solidityKeccak256:O1,splitSignature:B1}=te,Pi=class extends Ta{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=O1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=D1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=B1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Ni.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Di.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Oi.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Bi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Fi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Li.abi=Np;var{AddressZero:q1}=ht,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(On.extensionType),e.address);if(t===q1)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},Va=On;Va.supportedVersions=[{version:3,factory:Bi},{version:4,factory:Fi},{version:5,factory:Li}],Va.extensionType=we.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=vn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var Vs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var js=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=wn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Ph=async(a,e)=>{let t=await wp(e,a.signerOrProvider);switch(t.tokenClientType){case _n.Colony:return new Vs(a,t);case _n.Erc20:return new Bn(a,t);case _n.Erc2612:return new js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Ui.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Vi.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};ji.abi=Bp;var{AddressZero:Fp}=ht;var Hu=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(Fn.extensionType),e.address);if(t===Fp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Cs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Ol);return[e,t,Fp,Ol,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await vi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},ja=Fn;ja.supportedVersions=[{version:7,factory:Ui},{version:8,factory:Vi},{version:9,factory:ji}],ja.extensionType=we.VotingReputation;var K1={["motion"]:ja,["oneTx"]:Va},Or=class{static async connect(e,t){let n=await Ir(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Ph(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new na(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Va.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ta(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await vi(x,this.colony,r,s),_=await vi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=K1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Fa(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Ba(i),t.getLatestSupportedVersion()],async s=>({...ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return su(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Br=Or;Br.supportedVersions=[{version:11,factory:Ni},{version:12,factory:Di},{version:13,factory:Oi}];var{splitSignature:J1}=te,qu=class extends Ta{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=J1(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Hs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=_p(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Nh}=te,{AddressZero:Lp}=ht,qs=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Nr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||ru[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Er[this.network]},this.networkContract=Ri.connect(t?.customNetworkAddress||iu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Hs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new Ta({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Pi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Lp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Br.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Es[this.network],""):null}async getColonyAddress(e){let t=Nh(`${e}${Es[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Is[this.network],""):null}async getUserAddress(e){let t=Nh(`${e}${Is[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{formatEther:$1,isAddress:Q1}=te,X1=new ea.JsonRpcProvider("http://127.0.0.1:8545"),Y1=()=>new on("0x0355596cdb5e5242ad082c4fe3f8bbe48c9dba843fe1f99dd8272f487e70efae",X1),Z1=async a=>{let e=Y1(),i=await(await new qs(e,{customNetworkAddress:a,reputationOracleEndpoint:"http://localhost:3000"}).getMetaColony()).getBalance();return $1(i)},Vp=document.querySelector("#address"),Oh=document.querySelector("#button"),jp=document.querySelector("#error"),Bh=document.querySelector("#result");if(!Vp||!Oh||!jp||!Bh)throw new Error("Could not find all required HTML elements");var Dh=a=>{jp.innerText=a},eg=()=>{jp.innerText=""},Up=a=>{Bh.innerText=a};Oh.addEventListener("click",async()=>{eg();let a=Vp.value;if(!Q1(a))return Dh("This is not a valid address");Up("Thinking..."),Vp.value="";let e;try{e=await Z1(a),Up(`${e} CLNY in root domain of local MetaColony`)}catch(t){Dh(`Found an error: ${t.message}`),Up("")}return null});})(); /** * [js-sha3]{@link https://github.com/emn178/js-sha3} * diff --git a/local-motions.js b/local-motions.js index a0ed6913a..c2c6ebc3e 100644 --- a/local-motions.js +++ b/local-motions.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),ox)try{let a=window;a._ethers&&a._ethers.wordlists&&(a._ethers.wordlists[t]||B(a._ethers.wordlists,t,e))}catch{}}};var ux="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ps=null;function vc(n){if(ps==null&&(ps=ux.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),wn.check(n)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ps=null,new Error("BIP39 Wordlist for en (English) FAILED")}var pl=class extends wn{constructor(){super("en")}getWord(e){return vc(this),ps[e]}getWordIndex(e){return vc(this),ps.indexOf(e)}},yl=new pl;wn.register(yl);var wi={en:yl};var wc="hdnode/5.7.0";var ys=new E(wc),dx=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),lx=we("Bitcoin seed"),Tr=2147483648;function kc(n){return(1<=256)throw new Error("Depth too large!");return _c(ce([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,he(W(this.index),4),this.chainCode,this.privateKey!=null?ce(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new St(gr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~Tr));let a=new Uint8Array(37);if(e&Tr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");a.set(j(this.privateKey),1),t&&(t+="'")}else a.set(j(this.publicKey));for(let x=24;x>=0;x-=8)a[33+(x>>3)]=e>>24-x&255;let i=j(Ta(na.sha512,this.chainCode,a)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=qo(F.from(r).add(this.privateKey).mod(dx)):l=new Tn(W(r))._addPoint(this.publicKey);let p=t,c=this.mnemonic;return c&&(p=Object.freeze({phrase:c.phrase,path:t,locale:c.locale||"en"})),new St(gr,o,l,this.fingerprint,qo(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let a=this;for(let i=0;i=Tr)throw new Error("invalid path index - "+r);a=a._derive(Tr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=Tr)throw new Error("invalid path index - "+r);a=a._derive(s)}else throw new Error("invalid path component - "+r)}return a}static _fromSeed(e,t){let a=j(e);if(a.length<16||a.length>64)throw new Error("invalid seed");let i=j(Ta(na.sha512,lx,a));return new St(gr,qo(i.slice(0,32)),null,"0x00000000",qo(i.slice(32)),0,0,t)}static fromMnemonic(e,t,a){return a=cl(a),e=_i(vr(e,a),a),St._fromSeed(fl(e,t),{phrase:e,path:"m",locale:a.locale})}static fromSeed(e){return St._fromSeed(e,null)}static fromExtendedKey(e){let t=ga.decode(e);(t.length!==82||_c(t.slice(0,78))!==e)&&ys.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let a=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new St(gr,null,W(o),i,s,r,a,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new St(gr,W(o.slice(1)),null,i,s,r,a,null)}return ys.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function fl(n,e){e||(e="");let t=we("mnemonic"+e,Jt.NFKD);return vi(we(n,Jt.NFKD),t,2048,64,"sha512")}function vr(n,e){e=cl(e),ys.checkNormalize();let t=e.split(n);if(t.length%3!==0)throw new Error("invalid mnemonic");let a=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=kc(s);if((j(en(a.slice(0,r/8)))[0]&o)!==(a[a.length-1]&o))throw new Error("invalid checksum");return W(a.slice(0,r/8))}function _i(n,e){if(e=cl(e),n=j(n),n.length%4!==0||n.length<16||n.length>32)throw new Error("invalid entropy");let t=[0],a=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=n[s],a-=8):(t[t.length-1]<<=a,t[t.length-1]|=n[s]>>8-a,t.push(n[s]&px(8-a)),a+=3);let i=n.length/4,r=j(en(n))[0]&kc(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function Ac(n,e){try{return vr(n,e),!0}catch{}return!1}function Ec(n){return(typeof n!="number"||n<0||n>=Tr||n%1)&&ys.throwArgumentError("invalid account index","index",n),`m/44'/60'/${n}'/0/0`}var Mc="random/5.7.0";var ml=new E(Mc);function yx(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var Ic=yx(),zo=Ic.crypto||Ic.msCrypto;(!zo||!zo.getRandomValues)&&(ml.warn("WARNING: Missing strong random number source"),zo={getRandomValues:function(n){return ml.throwError("no secure random source avaialble",E.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function aa(n){(n<=0||n>1024||n%1||n!=n)&&ml.throwArgumentError("invalid length","length",n);let e=new Uint8Array(n);return zo.getRandomValues(e),j(e)}function cs(n){n=n.slice();for(let e=n.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),a=n[e];n[e]=n[t],n[t]=a}return n}var bl=Cn(xl());var Go="json-wallets/5.7.0";function wa(n){return typeof n=="string"&&n.substring(0,2)!=="0x"&&(n="0x"+n),j(n)}function wr(n,e){for(n=String(n);n.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),M=new _a.default.Counter(x),J=new _a.default.ModeOfOperation.ctr(O,M),$=j(J.encrypt(i)),de=fe(ce([U,$])),T={address:n.address.substring(2).toLowerCase(),id:Sc(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(c).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=aa(16),N=new _a.default.Counter(R),q=new _a.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+wr(I.getUTCMonth()+1,2)+"-"+wr(I.getUTCDate(),2)+"T"+wr(I.getUTCHours(),2)+"-"+wr(I.getUTCMinutes(),2)+"-"+wr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function Uc(n,e,t){if(Wo(n)){t&&t(0);let a=Tl(n,e);return t&&t(1),Promise.resolve(a)}return Ko(n)?Lc(n,e,t):Promise.reject(new Error("invalid JSON wallet"))}function Vc(n,e){if(Wo(n))return Tl(n,e);if(Ko(n))return Fc(n,e);throw new Error("invalid JSON wallet")}var jc="wallet/5.7.0";var Hc=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},_r=new E(jc);function xx(n){return n!=null&&ie(n.privateKey,32)&&n.address!=null}function bx(n){let e=n.mnemonic;return e&&e.phrase}var ln=class extends Nt{constructor(e,t){if(super(),xx(e)){let a=new Tn(e.privateKey);if(B(this,"_signingKey",()=>a),B(this,"address",vn(this.publicKey)),this.address!==me(e.address)&&_r.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),bx(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||va,locale:i.locale||"en"}));let r=this.mnemonic,s=St.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);vn(s.privateKey)!==this.address&&_r.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(Tn.isSigningKey(e))e.curve!=="secp256k1"&&_r.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let a=new Tn(e);B(this,"_signingKey",()=>a)}B(this,"_mnemonic",()=>null),B(this,"address",vn(this.publicKey))}t&&!Xt.isProvider(t)&&_r.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new ln(this,e)}signTransaction(e){return Re(e).then(t=>{t.from!=null&&(me(t.from)!==this.address&&_r.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let a=this._signingKey().signDigest(fe(us(t)));return us(t,a)})}signMessage(e){return Hc(this,void 0,void 0,function*(){return Wr(this._signingKey().signDigest(sr(e)))})}_signTypedData(e,t,a){return Hc(this,void 0,void 0,function*(){let i=yield vt.resolveNames(e,t,a,r=>(this.provider==null&&_r.throwError("cannot resolve ENS names without a provider",E.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return Wr(this._signingKey().signDigest(vt.hash(i.domain,t,i.value)))})}encrypt(e,t,a){if(typeof t=="function"&&!a&&(a=t,t={}),a&&typeof a!="function")throw new Error("invalid callback");return t||(t={}),Al(this,e,t,a)}static createRandom(e){let t=aa(16);e||(e={}),e.extraEntropy&&(t=j(Se(fe(ce([t,e.extraEntropy])),0,16)));let a=_i(t,e.locale);return ln.fromMnemonic(a,e.path,e.locale)}static fromEncryptedJson(e,t,a){return Uc(e,t,a).then(i=>new ln(i))}static fromEncryptedJsonSync(e,t){return new ln(Vc(e,t))}static fromMnemonic(e,t,a){return t||(t=va),new ln(St.fromMnemonic(e,null,a).derivePath(t))}};function qc(n,e){return bi(sr(n),e)}function zc(n,e,t,a){return bi(vt.hash(n,e,t),a)}var sa={};Ji(sa,{AlchemyProvider:()=>Cr,AlchemyWebSocketProvider:()=>As,AnkrProvider:()=>Es,BaseProvider:()=>ra,CloudflareProvider:()=>Ms,EtherscanProvider:()=>Is,FallbackProvider:()=>Ss,Formatter:()=>X,InfuraProvider:()=>Rr,InfuraWebSocketProvider:()=>Ps,IpcProvider:()=>Ll,JsonRpcBatchProvider:()=>du,JsonRpcProvider:()=>tn,JsonRpcSigner:()=>Mr,NodesmithProvider:()=>Ns,PocketProvider:()=>Ds,Provider:()=>Xt,Resolver:()=>Er,StaticJsonRpcProvider:()=>ks,UrlJsonRpcProvider:()=>Rt,Web3Provider:()=>Os,WebSocketProvider:()=>Ea,getDefaultProvider:()=>lu,getNetwork:()=>ms,isCommunityResourcable:()=>Il,isCommunityResource:()=>bs,showThrottleMessage:()=>ia});var Gc="networks/5.7.1";var Wc=new E(Gc);function gx(n){return n&&typeof n.renetwork=="function"}function ka(n){let e=function(t,a){a==null&&(a={});let i=[];if(t.InfuraProvider&&a.infura!=="-")try{i.push(new t.InfuraProvider(n,a.infura))}catch{}if(t.EtherscanProvider&&a.etherscan!=="-")try{i.push(new t.EtherscanProvider(n,a.etherscan))}catch{}if(t.AlchemyProvider&&a.alchemy!=="-")try{i.push(new t.AlchemyProvider(n,a.alchemy))}catch{}if(t.PocketProvider&&a.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(n,a.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&a.cloudflare!=="-")try{i.push(new t.CloudflareProvider(n))}catch{}if(t.AnkrProvider&&a.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(n,a.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return a.quorum!=null?r=a.quorum:n==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return ka(t)},e}function Qo(n,e){let t=function(a,i){return a.JsonRpcProvider?new a.JsonRpcProvider(n,e):null};return t.renetwork=function(a){return Qo(n,a)},t}var Kc={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:ka("homestead")},Jc={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:ka("ropsten")},$c={chainId:63,name:"classicMordor",_defaultProvider:Qo("https://www.ethercluster.com/mordor","classicMordor")},$o={unspecified:{chainId:0,name:"unspecified"},homestead:Kc,mainnet:Kc,morden:{chainId:2,name:"morden"},ropsten:Jc,testnet:Jc,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:ka("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:ka("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:ka("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:ka("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Qo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:$c,classicTestnet:$c,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Qo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:ka("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:ka("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ms(n){if(n==null)return null;if(typeof n=="number"){for(let a in $o){let i=$o[a];if(i.chainId===n)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:n,name:"unknown"}}if(typeof n=="string"){let a=$o[n];return a==null?null:{name:a.name,chainId:a.chainId,ensAddress:a.ensAddress,_defaultProvider:a._defaultProvider||null}}let e=$o[n.name];if(!e)return typeof n.chainId!="number"&&Wc.throwArgumentError("invalid network chainId","network",n),n;n.chainId!==0&&n.chainId!==e.chainId&&Wc.throwArgumentError("network chainId mismatch","network",n);let t=n._defaultProvider||null;return t==null&&e._defaultProvider&&(gx(e._defaultProvider)?t=e._defaultProvider.renetwork(n):t=e._defaultProvider),{name:n.name,chainId:e.chainId,ensAddress:n.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Qc="web/5.7.1";var Tx=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})};function Yc(n,e){return Tx(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let a=yield fetch(n,t),i=yield a.arrayBuffer(),r={};return a.headers.forEach?a.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):a.headers.keys().forEach(s=>{r[s.toLowerCase()]=a.headers.get(s)}),{headers:r,statusCode:a.status,statusMessage:a.statusText,body:j(new Uint8Array(i))}})}var vx=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},On=new E(Qc);function Xc(n){return new Promise(e=>{setTimeout(e,n)})}function ja(n,e){if(n==null)return null;if(typeof n=="string")return n;if(la(n)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Yt(n)}catch{}return W(n)}return n}function wx(n){return we(n.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function El(n,e,t){let a=typeof n=="object"&&n.throttleLimit!=null?n.throttleLimit:12;On.assertArgument(a>0&&a%1===0,"invalid connection throttle limit","connection.throttleLimit",a);let i=typeof n=="object"?n.throttleCallback:null,r=typeof n=="object"&&typeof n.throttleSlotInterval=="number"?n.throttleSlotInterval:100;On.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof n=="object"?!!n.errorPassThrough:!1,o={},l=null,p={method:"GET"},c=!1,x=2*60*1e3;if(typeof n=="string")l=n;else if(typeof n=="object"){if((n==null||n.url==null)&&On.throwArgumentError("missing URL","connection.url",n),l=n.url,typeof n.timeout=="number"&&n.timeout>0&&(x=n.timeout),n.headers)for(let O in n.headers)o[O.toLowerCase()]={key:O,value:String(n.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(c=!0);if(p.allowGzip=!!n.allowGzip,n.user!=null&&n.password!=null){l.substring(0,6)!=="https:"&&n.allowInsecureAuthentication!==!0&&On.throwError("basic authentication requires a secure https url",E.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:n.user,password:"[REDACTED]"});let O=n.user+":"+n.password;o.authorization={key:"Authorization",value:"Basic "+rr(we(O))}}n.skipFetchSetup!=null&&(p.skipFetchSetup=!!n.skipFetchSetup),n.fetchOptions!=null&&(p.fetchOptions=_e(n.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?ir(_[3]):wx(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){On.throwError("processing response error",E.errors.SERVER_ERROR,{body:ja(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(M,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(On.makeError("timeout",E.errors.TIMEOUT,{requestBody:ja(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return vx(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),On.throwError("bad response",E.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:ja(H,U.headers?U.headers["content-type"]:null),requestBody:ja(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let M=yield t(H,U);return S.cancel(),M}catch(M){if(M.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Yt(r))}catch(l){On.throwError("invalid JSON",E.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=we(e);let r=typeof n=="string"?{url:n}:_e(n);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},n=r}return El(n,i,a)}function Fn(n,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,a){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&a(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return n().then(function(c){if(c!==void 0)s()&&t(c);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&a(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(c){s()&&a(c)})}p()})}var Pl=Cn(nf());var Ee="providers/5.7.2";var xs=new E(Ee),X=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),a=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),c=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:X.allowNull(this.accessList.bind(this),null),blockHash:X.allowNull(s,null),blockNumber:X.allowNull(l,null),transactionIndex:X.allowNull(l,null),confirmations:X.allowNull(l,null),from:t,gasPrice:X.allowNull(a),maxPriorityFeePerGas:X.allowNull(a),maxFeePerGas:X.allowNull(a),gasLimit:a,to:X.allowNull(t,null),value:a,nonce:l,data:r,r:X.allowNull(this.uint256),s:X.allowNull(this.uint256),v:X.allowNull(l),creates:X.allowNull(t,null),raw:X.allowNull(r)},e.transactionRequest={from:X.allowNull(t),nonce:X.allowNull(l),gasLimit:X.allowNull(a),gasPrice:X.allowNull(a),maxPriorityFeePerGas:X.allowNull(a),maxFeePerGas:X.allowNull(a),to:X.allowNull(t),value:X.allowNull(a),data:X.allowNull(c),type:X.allowNull(l),accessList:X.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:X.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:X.allowNull(this.address,null),from:X.allowNull(this.address,null),contractAddress:X.allowNull(t,null),transactionIndex:l,root:X.allowNull(o),gasUsed:a,logsBloom:X.allowNull(r),blockHash:s,transactionHash:s,logs:X.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:X.allowNull(l,null),cumulativeGasUsed:a,effectiveGasPrice:X.allowNull(a),status:X.allowNull(l),type:p},e.block={hash:X.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:X.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:a,gasUsed:a,miner:X.allowNull(t),extraData:r,transactions:X.allowNull(X.arrayOf(s)),baseFeePerGas:X.allowNull(a)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=X.allowNull(X.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:X.allowNull(i,void 0),toBlock:X.allowNull(i,void 0),blockHash:X.allowNull(s,void 0),address:X.allowNull(t,void 0),topics:X.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:X.allowNull(l),blockHash:X.allowNull(s),transactionIndex:l,removed:X.allowNull(this.boolean.bind(this)),address:t,data:X.allowFalsish(r,"0x"),topics:X.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return dn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():xs.throwArgumentError("invalid hash","value",e)}data(e,t){let a=this.hex(e,t);if(a.length%2!==0)throw new Error("invalid data; odd-length - "+e);return a}address(e){return me(e)}callAddress(e){if(!ie(e,32))return null;let t=me(Se(e,12));return t===mo?null:t}contractAddress(e){return fi(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return zn(e);throw new Error("invalid blockTag")}hash(e,t){let a=this.hex(e,t);return Ft(a)!==32?xs.throwArgumentError("invalid hash","value",e):a}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return he(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let a=e._difficulty!=null?e._difficulty:e.difficulty,i=X.check(t,e);return i._difficulty=a==null?null:F.from(a),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return X.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=X.check(this.formats.transaction,e);if(e.chainId!=null){let a=e.chainId;ie(a)&&(a=F.from(a).toNumber()),t.chainId=a}else{let a=e.networkId;a==null&&t.v==null&&(a=e.chainId),ie(a)&&(a=F.from(a).toNumber()),typeof a!="number"&&t.v!=null&&(a=(t.v-35)/2,a<0&&(a=0),a=parseInt(a)),typeof a!="number"&&(a=0),t.chainId=a}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return Fo(e)}receiptLog(e){return X.check(this.formats.receiptLog,e)}receipt(e){let t=X.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let a=F.from(t.root).toNumber();a===0||a===1?(t.status!=null&&t.status!==a&&xs.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=a,delete t.root):xs.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&xs.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return X.check(this.formats.filter,e)}filterLog(e){return X.check(this.formats.filterLog,e)}static check(e,t){let a={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(a[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return a}static allowNull(e,t){return function(a){return a==null?t:e(a)}}static allowFalsish(e,t){return function(a){return a?e(a):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let a=[];return t.forEach(function(i){a.push(e(i))}),a}}};function Il(n){return n&&typeof n.isCommunityResource=="function"}function bs(n){return Il(n)&&n.isCommunityResource()}var af=!1;function ia(){af||(af=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},xe=new E(Ee),Sx=10;function rf(n){return n==null?"null":(Ft(n)!==32&&xe.throwArgumentError("invalid topic","topic",n),n.toLowerCase())}function sf(n){for(n=n.slice();n.length>0&&n[n.length-1]==null;)n.pop();return n.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[rf(i)]=!0});let a=Object.keys(t);return a.sort(),a.join("|")}else return rf(e)}).join("&")}function Rx(n){return n===""?[]:n.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(a=>a==="null"?null:a);return t.length===1?t[0]:t})}function Ar(n){if(typeof n=="string"){if(n=n.toLowerCase(),Ft(n)===32)return"tx:"+n;if(n.indexOf(":")===-1)return n}else{if(Array.isArray(n))return"filter:*:"+sf(n);if(Eo.isForkEvent(n))throw xe.warn("not implemented"),new Error("not implemented");if(n&&typeof n=="object")return"filter:"+(n.address||"*")+":"+sf(n.topics||[])}throw new Error("invalid event - "+n)}function gs(){return new Date().getTime()}function of(n){return new Promise(e=>{setTimeout(e,n)})}var Px=["block","network","pending","poll"],Nl=class{constructor(e,t,a){B(this,"tag",e),B(this,"listener",t),B(this,"once",a),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],a=Rx(e[2]),i={};return a.length>0&&(i.topics=a),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||Px.indexOf(this.tag)>=0}},Nx={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Cl(n){return he(F.from(n).toHexString(),32)}function uf(n){return ga.encode(ce([n,Se(en(en(n)),0,4)]))}var pf=new RegExp("^(ipfs)://(.*)$","i"),df=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),pf,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function eu(n,e){try{return Yt(Ts(n,e))}catch{}return null}function Ts(n,e){if(n==="0x")return null;let t=F.from(Se(n,e,e+32)).toNumber(),a=F.from(Se(n,t,t+32)).toNumber();return Se(n,t+32,t+32+a)}function Sl(n){return n.match(/^ipfs:\/\/ipfs\//i)?n=n.substring(12):n.match(/^ipfs:\/\//i)?n=n.substring(7):xe.throwArgumentError("unsupported IPFS format","link",n),`https://gateway.ipfs.io/ipfs/${n}`}function lf(n){let e=j(n);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function Dx(n){if(n.length%32===0)return n;let e=new Uint8Array(Math.ceil(n.length/32)*32);return e.set(n),e}function yf(n){let e=[],t=0;for(let a=0;aF.from(e).eq(1)).catch(e=>{if(e.code===E.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let a={to:this.address,ccipReadEnabled:!0,data:Et([e,Oa(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,a.data=Et(["0x9061b923",yf([is(this.name),a.data])]));try{let r=yield this.provider.call(a);return j(r).length%32===4&&xe.throwError("resolver threw error",E.errors.CALL_EXCEPTION,{transaction:a,data:r}),i&&(r=Ts(r,0)),r}catch(r){if(r.code===E.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let a=yield this._fetch(e,t);return a!=null?Ts(a,0):null})}_getAddress(e,t){let a=Nx[String(e)];if(a==null&&xe.throwError(`unsupported coin type: ${e}`,E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),a.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(a.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return uf(ce([[a.p2pkh],"0x"+r[2]]))}}if(a.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return uf(ce([[a.p2sh],"0x"+r[2]]))}}if(a.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=Pl.default.toWords(i.slice(2));return o.unshift(s),Pl.default.encode(a.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===nr?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===E.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",Cl(e));if(t==null||t==="0x")return null;let a=this._getAddress(e,t);return a==null&&xe.throwError("invalid or unsupported coin data",E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),a})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let a=0;as[l]);return"sia://"+o}return xe.throwError("invalid or unsupported content hash data",E.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=we(e);t=ce([Cl(64),Cl(t.length),t]),t.length%32!==0&&(t=ce([t,he("0x",32-e.length%32)]));let a=yield this._fetchBytes("0x59d1d43c",W(t));return a==null||a==="0x"?null:Yt(a)})}},Rl=null,Ox=1,ra=class extends Xt{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=bt(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):xe.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||xe.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Fn(()=>this._ready().then(e=>e,e=>{if(!(e.code===E.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return Rl==null&&(Rl=new X),Rl}static getNetwork(e){return ms(e??"homestead")}ccipReadFetch(e,t,a){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||a.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Bn({url:p,errorPassThrough:!0},c,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return xe.throwError(`response not found during CCIP fetch: ${C}`,E.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return xe.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,E.errors.SERVER_ERROR,{urls:a,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(gs()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=gs(),a=Re({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===a&&(this._internalBlockNumber=null),r;let s=gs();return i=F.from(i).toNumber(),i{this._internalBlockNumber===a&&(this._internalBlockNumber=null)}),(yield a).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=Ox++,t=[],a=null;try{a=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(a),this.emit("poll",e,a),a===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=a-1),Math.abs(this._emitted.block-a)>1e3)xe.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${a})`),this.emit("error",xe.makeError("network block skew detected",E.errors.NETWORK_ERROR,{blockNumber:a,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",a);else for(let i=this._emitted.block+1;i<=a;i++)this.emit("block",i);this._emitted.block!==a&&(this._emitted.block=a,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&a-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=a-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=a-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=a;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=a,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return xe.throwError("provider does not support network detection",E.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield of(0),this._network;let a=xe.makeError("underlying network changed",E.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",a),a}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=gs();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,a){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,a||0,null)})}_waitForTransaction(e,t,a,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,c=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield of(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof a=="number"&&a>0){let C=setTimeout(()=>{c()||o(xe.makeError("timeout exceeded",E.errors.TIMEOUT,{timeout:a}))},a);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let a=yield Re({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",a);try{return F.from(i)}catch(r){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getBalance",params:a,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let a=yield Re({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",a);try{return F.from(i).toNumber()}catch(r){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getTransactionCount",params:a,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let a=yield Re({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",a);try{return W(i)}catch(r){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getCode",params:a,result:i,error:r})}})}getStorageAt(e,t,a){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Re({address:this._getAddress(e),blockTag:this._getBlockTag(a),position:Promise.resolve(t).then(s=>zn(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,a){if(t!=null&&Ft(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&xe.throwError("Transaction hash mismatch from Provider.sendTransaction.",E.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&a!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:a});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&xe.throwError("transaction failed",E.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),a=this.formatter.transaction(e);a.confirmations==null&&(a.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(a,r,i)}catch(r){throw r.transaction=a,r.transactionHash=a.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,a={};return["from","to"].forEach(i=>{t[i]!=null&&(a[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(a[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(a[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(a.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(a[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Re(a))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(a=>{e[a]!=null&&(t[a]=e[a])}),["fromBlock","toBlock"].forEach(a=>{e[a]!=null&&(t[a]=this._getBlockTag(e[a]))}),this.formatter.filter(yield Re(t))})}_call(e,t,a){return ue(this,void 0,void 0,function*(){a>=Sx&&xe.throwError("CCIP read exceeded maximum redirections",E.errors.SERVER_ERROR,{redirects:a,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(a>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Ft(r)%32===4)try{let s=Se(r,4),o=Se(s,0,32);F.from(o).eq(i)||xe.throwError("CCIP Read sender did not match",E.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Se(s,32,64)).toNumber(),c=F.from(Se(s,p,p+32)).toNumber(),x=Se(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&a>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Fn(()=>ue(this,void 0,void 0,function*(){let a=yield this.perform("getTransaction",t);if(a==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(a);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Fn(()=>ue(this,void 0,void 0,function*(){let a=yield this.perform("getTransactionReceipt",t);if(a==null)return this._emitted["t:"+e]==null?null:void 0;if(a.blockHash==null)return;let i=this.formatter.receipt(a);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Re({filter:this._getFilter(e)}),a=yield this.perform("getLogs",t);return a.forEach(i=>{i.removed==null&&(i.removed=!1)}),X.arrayOf(this.formatter.filterLog.bind(this.formatter))(a)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&xe.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let a=yield this._getResolver(t,"getResolver");if(a!=null){let i=new Er(this,a,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let a=yield this.getNetwork();a.ensAddress||xe.throwError("network does not support ENS",E.errors.UNSUPPORTED_OPERATION,{operation:t,network:a.name});try{let i=yield this.call({to:a.ensAddress,data:"0x0178b8bf"+Oa(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(a){if(ie(e))throw a}typeof e!="string"&&xe.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",a=yield this._getResolver(t,"lookupAddress");if(a==null)return null;let i=eu(yield this.call({to:a,data:"0x691f3431"+Oa(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new Er(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o}try{let o=eu(yield this.call({to:s,data:"0x691f3431"+Oa(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let a=yield t.getAvatar();return a==null?null:a.url})}perform(e,t){return xe.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,a){let i=new Nl(Ar(e),t,a);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let a=!1,i=[],r=Ar(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),a=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),a}listenerCount(e){if(!e)return this._events.length;let t=Ar(e);return this._events.filter(a=>a.tag===t).length}listeners(e){if(e==null)return this._events.map(a=>a.listener);let t=Ar(e);return this._events.filter(a=>a.tag===t).map(a=>a.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let a=[],i=!1,r=Ar(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,a.push(s),!1)),a.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let a=Ar(e);this._events=this._events.filter(i=>i.tag!==a?!0:(t.push(i),!1))}return t.forEach(a=>{this._stopEvent(a)}),this}};var Aa=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},It=new E(Ee),Bx=["call","estimateGas"];function ws(n,e){if(n==null)return null;if(typeof n.message=="string"&&n.message.match("reverted")){let t=ie(n.data)?n.data:null;if(!e||t)return{message:n.message,data:t}}if(typeof n=="object"){for(let t in n){let a=ws(n[t],e);if(a)return a}return null}if(typeof n=="string")try{return ws(JSON.parse(n),e)}catch{}return null}function ff(n,e,t){let a=t.transaction||t.signedTransaction;if(n==="call"){let r=ws(e,!0);if(r)return r.data;It.throwError("missing revert data in call exception; Transaction reverted without a reason string",E.errors.CALL_EXCEPTION,{data:"0x",transaction:a,error:e})}if(n==="estimateGas"){let r=ws(e.body,!1);r==null&&(r=ws(e,!1)),r&&It.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:n,transaction:a,error:e})}let i=e.message;throw e.code===E.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&It.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:n,transaction:a}),i.match(/nonce (is )?too low/i)&&It.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:n,transaction:a}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&It.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:n,transaction:a}),i.match(/only replay-protected/i)&&It.throwError("legacy pre-eip-155 transactions not supported",E.errors.UNSUPPORTED_OPERATION,{error:e,method:n,transaction:a}),Bx.indexOf(n)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&It.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:n,transaction:a}),e}function cf(n){return new Promise(function(e){setTimeout(e,n)})}function Fx(n){if(n.error){let e=new Error(n.error.message);throw e.code=n.error.code,e.data=n.error.data,e}return n.result}function vs(n){return n&&n.toLowerCase()}var Dl={},Mr=class extends Nt{constructor(e,t,a){if(super(),e!==Dl)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),a==null&&(a=0),typeof a=="string"?(B(this,"_address",this.provider.formatter.address(a)),B(this,"_index",null)):typeof a=="number"?(B(this,"_index",a),B(this,"_address",null)):It.throwArgumentError("invalid address or index","addressOrIndex",a)}connect(e){return It.throwError("cannot alter JSON-RPC Signer connection",E.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new Ol(Dl,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&It.throwError("unknown account #"+this._index,E.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(a=>(a&&(a=a.toLowerCase()),a));if(e.gasLimit==null){let a=_e(e);a.from=t,e.gasLimit=this.provider.estimateGas(a)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(a=>Aa(this,void 0,void 0,function*(){if(a==null)return null;let i=yield this.provider.resolveName(a);return i==null&&It.throwArgumentError("provided ENS name resolves to null","tx.to",a),i}))),Re({tx:Re(e),sender:t}).then(({tx:a,sender:i})=>{a.from!=null?a.from.toLowerCase()!==i&&It.throwArgumentError("from address mismatch","transaction",e):a.from=i;let r=this.provider.constructor.hexlifyTransaction(a,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&It.throwError("user rejected transaction",E.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:a}),ff("sendTransaction",s,r)))})}signTransaction(e){return It.throwError("signing transactions is unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return Aa(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),a=yield this.sendUncheckedTransaction(e);try{return yield Fn(()=>Aa(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(a);if(i!==null)return this.provider._wrapTransaction(i,a,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=a,i}})}signMessage(e){return Aa(this,void 0,void 0,function*(){let t=typeof e=="string"?we(e):e,a=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),a.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&It.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"signMessage",from:a,messageData:e}),i}})}_legacySignMessage(e){return Aa(this,void 0,void 0,function*(){let t=typeof e=="string"?we(e):e,a=yield this.getAddress();try{return yield this.provider.send("eth_sign",[a.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&It.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:a,messageData:e}),i}})}_signTypedData(e,t,a){return Aa(this,void 0,void 0,function*(){let i=yield vt.resolveNames(e,t,a,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(vt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&It.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return Aa(this,void 0,void 0,function*(){let t=this.provider,a=yield this.getAddress();return t.send("personal_unlockAccount",[a.toLowerCase(),e,null])})}},Ol=class extends Mr{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:a=>this.provider.waitForTransaction(t,a)}))}},Lx={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},tn=class extends ra{constructor(e,t){let a=t;a==null&&(a=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(a),e||(e=bt(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return Aa(this,void 0,void 0,function*(){yield cf(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=bt(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(a){return It.throwError("could not detect network",E.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:a})}}return It.throwError("could not detect network",E.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new Mr(Dl,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let a={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:xt(a),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Bn(this.connection,JSON.stringify(a),Fx).then(s=>(this.emit("debug",{action:"response",request:a,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:a,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[vs(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[vs(t.address),t.blockTag]];case"getCode":return["eth_getCode",[vs(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[vs(t.address),he(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let a=bt(this.constructor,"hexlifyTransaction");return["eth_call",[a(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let a=bt(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[a(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=vs(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return Aa(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let a=this.prepareRequest(e,t);a==null&&It.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(a[0],a[1])}catch(i){return ff(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(a){function i(){e.send("eth_getFilterChanges",[a]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return cf(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[a]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),a}).catch(a=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let a=_e(Lx);if(t)for(let r in t)t[r]&&(a[r]=!0);Yi(e,a);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=zn(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=dn(e.accessList)),i}};var Ir=null;try{if(Ir=WebSocket,Ir==null)throw new Error("inject please")}catch{let e=new E(Ee);Ir=function(){e.throwError("WebSockets not supported in this environment",E.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var Bl=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},tu=new E(Ee),Ux=1,Ea=class extends tn{constructor(e,t){t==="any"&&tu.throwError("WebSocketProvider does not support 'any' network yet",E.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new Ir(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let a=setInterval(()=>{this.emit("poll")},1e3);a.unref&&a.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){tu.throwError("cannot reset events block on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){tu.throwError("cannot set polling interval on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return Bl(this,void 0,void 0,function*(){return null})}set polling(e){!e||tu.throwError("cannot set polling on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let a=Ux++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:a,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(a)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,a){return Bl(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:a}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let a=F.from(t.number).toNumber();this._emitted.block=a,this.emit("block",a)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=a=>{let i=a.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],a=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let a=this._subIds[t];!a||(delete this._subIds[t],a.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return Bl(this,void 0,void 0,function*(){this.websocket.readyState===Ir.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var Vx=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},_s=new E(Ee),ks=class extends tn{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return Vx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||_s.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Rt=class extends ks{constructor(e,t){_s.checkAbstract(new.target,Rt),e=bt(new.target,"getNetwork")(e),t=bt(new.target,"getApiKey")(t);let a=bt(new.target,"getUrl")(e,t);super(a,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){_s.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return _s.throwError("API provider does not support signing",E.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return _s.throwError("not implemented; sub-classes must override getUrl",E.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var mf=new E(Ee),nu="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",As=class extends Ea{constructor(e,t){let a=new Cr(e,t),i=a.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,a.network),B(this,"apiKey",a.apiKey)}isCommunityResource(){return this.apiKey===nu}},Cr=class extends Rt{static getWebSocketProvider(e,t){return new As(e,t)}static getApiKey(e){return e==null?nu:(e&&typeof e!="string"&&mf.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let a=null;switch(e.name){case"homestead":a="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":a="eth-goerli.g.alchemy.com/v2/";break;case"matic":a="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":a="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":a="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":a="arb-goerli.g.alchemy.com/v2/";break;case"optimism":a="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":a="opt-goerli.g.alchemy.com/v2/";break;default:mf.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+a+t,throttleCallback:(i,r)=>(t===nu&&ia(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===nu}};var jx=new E(Ee),au="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function Hx(n){switch(n){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return jx.throwArgumentError("unsupported network","name",n)}var Es=class extends Rt{isCommunityResource(){return this.apiKey===au}static getApiKey(e){return e??au}static getUrl(e,t){t==null&&(t=au);let a={allowGzip:!0,url:"https://"+Hx(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===au&&ia(),Promise.resolve(!0))};return t.projectSecret!=null&&(a.user="",a.password=t.projectSecret),a}};var qx=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},hf=new E(Ee),Ms=class extends Rt{static getApiKey(e){return e!=null&&hf.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let a=null;switch(e.name){case"homestead":a="https://cloudflare-eth.com/";break;default:hf.throwArgumentError("unsupported network","network",arguments[0])}return a}perform(e,t){let a=Object.create(null,{perform:{get:()=>super.perform}});return qx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield a.perform.call(this,"getBlock",{blockTag:"latest"})).number:a.perform.call(this,e,t)})}};var iu=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},Ha=new E(Ee);function xf(n){let e={};for(let t in n){if(n[t]==null)continue;let a=n[t];t==="type"&&a===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?a=zn(W(a)):t==="accessList"?a="["+dn(a).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":a=W(a),e[t]=a)}return e}function zx(n){if(n.status==0&&(n.message==="No records found"||n.message==="No transactions found"))return n.result;if(n.status!=1||typeof n.message!="string"||!n.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(n),(n.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return n.result}function bf(n){if(n&&n.status==0&&n.message=="NOTOK"&&(n.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(n),e.throttleRetry=!0,e}if(n.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(n),e}if(n.error){let e=new Error(n.error.message||"unknown error");throw n.error.code&&(e.code=n.error.code),n.error.data&&(e.data=n.error.data),e}return n.result}function gf(n){if(n==="pending")throw new Error("pending not supported");return n==="latest"?n:parseInt(n.substring(2),16)}function Fl(n,e,t){if(n==="call"&&e.code===E.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Ha.throwError("missing revert data in call exception",E.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let a=e.message;throw e.code===E.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?a=e.error.message:typeof e.body=="string"?a=e.body:typeof e.responseText=="string"&&(a=e.responseText)),a=(a||"").toLowerCase(),a.match(/insufficient funds/)&&Ha.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:n,transaction:t}),a.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Ha.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:n,transaction:t}),a.match(/another transaction with same nonce/)&&Ha.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:n,transaction:t}),a.match(/execution failed due to an exception|execution reverted/)&&Ha.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:n,transaction:t}),e}var Is=class extends ra{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Ha.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let a=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${a}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,a){return iu(this,void 0,void 0,function*(){let i=a?this.getPostUrl():this.getUrl(e,t),r=a?this.getPostData(e,t):null,s=e==="proxy"?bf:zx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(c,x)=>(this.isCommunityResource()&&ia(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(c=>`${c}=${r[c]}`).join("&"));let p=yield Bn(o,l,s||bf);return this.emit("debug",{action:"response",request:i,response:xt(p),provider:this}),p})}detectNetwork(){return iu(this,void 0,void 0,function*(){return this.network})}perform(e,t){let a=Object.create(null,{perform:{get:()=>super.perform}});return iu(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Fl("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=xf(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Fl("call",r,t.transaction)}}case"estimateGas":{let i=xf(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Fl("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=gf(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=gf(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Ha.throwError("unsupported topic count",E.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Ha.throwError("unsupported topic format",E.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var ou=function(n,e,t,a){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(a.next(c))}catch(x){s(x)}}function l(c){try{p(a.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((a=a.apply(n,e||[])).next())})},ki=new E(Ee);function ru(){return new Date().getTime()}function Tf(n){let e=null;for(let t=0;te?null:(a+i)/2}function Sr(n){if(n===null)return"null";if(typeof n=="number"||typeof n=="boolean")return JSON.stringify(n);if(typeof n=="string")return n;if(F.isBigNumber(n))return n.toString();if(Array.isArray(n))return JSON.stringify(n.map(e=>Sr(e)));if(typeof n=="object"){let e=Object.keys(n);return e.sort(),"{"+e.map(t=>{let a=n[t];return typeof a=="function"?a="[function]":a=Sr(a),JSON.stringify(t)+":"+a}).join(",")+"}"}throw new Error("unknown value type: "+typeof n)}var Gx=1;function wf(n){let e=null,t=null,a=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,n)}),i=s=>(a=a.then(s),a);function r(){return a}return{cancel:e,getPromise:r,wait:i}}var Wx=[E.errors.CALL_EXCEPTION,E.errors.INSUFFICIENT_FUNDS,E.errors.NONCE_EXPIRED,E.errors.REPLACEMENT_UNDERPRICED,E.errors.UNPREDICTABLE_GAS_LIMIT],Kx=["address","args","errorArgs","errorSignature","method","transaction"];function su(n,e){let t={weight:n.weight};return Object.defineProperty(t,"provider",{get:()=>n.provider}),n.start&&(t.start=n.start),e&&(t.duration=e-n.start),n.done&&(n.error?t.error=n.error:t.result=n.result||null),t}function Jx(n,e){return function(t){let a={};t.forEach(r=>{let s=n(r.result);a[s]||(a[s]={count:0,result:r.result}),a[s].count++});let i=Object.keys(a);for(let r=0;r=e)return s.result}}}function $x(n,e,t){let a=Sr;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=vf(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=n._highestBlockNumber&&(n._highestBlockNumber=s),n._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return vf(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":a=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,Sr(i))};break;case"getBlock":t.includeTransactions?a=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),Sr(i))}:a=function(i){return i==null?null:Sr(i)};break;default:throw new Error("unknown method: "+e)}return Jx(a,n.quorum)}function Cs(n,e){return ou(this,void 0,void 0,function*(){let t=n.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Fn(()=>new Promise((a,i)=>{setTimeout(function(){return t.blockNumber>=e?a(t):n.cancelled?a(null):a(void 0)},0)}),{oncePoll:t})})}function Qx(n,e,t,a){return ou(this,void 0,void 0,function*(){let i=n.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return a.blockTag&&ie(a.blockTag)&&(i=yield Cs(n,e)),i[t](a.address,a.blockTag||"latest");case"getStorageAt":return a.blockTag&&ie(a.blockTag)&&(i=yield Cs(n,e)),i.getStorageAt(a.address,a.position,a.blockTag||"latest");case"getBlock":return a.blockTag&&ie(a.blockTag)&&(i=yield Cs(n,e)),i[a.includeTransactions?"getBlockWithTransactions":"getBlock"](a.blockTag||a.blockHash);case"call":case"estimateGas":return a.blockTag&&ie(a.blockTag)&&(i=yield Cs(n,e)),t==="call"&&a.blockTag?i[t](a.transaction,a.blockTag):i[t](a.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](a.transactionHash);case"getLogs":{let r=a.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield Cs(n,e)),i.getLogs(r)}}return ki.throwError("unknown method error",E.errors.UNKNOWN_ERROR,{method:t,params:a})})}var Ss=class extends ra{constructor(e,t){e.length===0&&ki.throwArgumentError("missing providers","providers",e);let a=e.map((s,o)=>{if(Xt.isProvider(s)){let c=bs(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:c,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=bs(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&ki.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=a.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&ki.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=Tf(a.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(a)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return ou(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return Tf(e)})}perform(e,t){return ou(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(c=>c.hash,c=>c)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=ru(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=Qx(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:su(_,ru()),request:{method:e,params:xt(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:su(_,ru()),request:{method:e,params:xt(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:su(_,null),request:{method:e,params:xt(t)},provider:this}),p+=_.weight}let c=[];i.forEach(_=>{_.done||!_.runner||(c.push(_.runner),_.staller&&c.push(_.staller.getPromise()))}),c.length&&(yield Promise.race(c));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=a(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield wf(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return Wx.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};Kx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),ki.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),ki.throwError("failed to meet quorum",E.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>su(l)),provider:this})})}};var Ll=null;var uu=new E(Ee),Rs="84842078b09946638c03157f83405213",Ps=class extends Ea{constructor(e,t){let a=new Rr(e,t),i=a.connection;i.password&&uu.throwError("INFURA WebSocket project secrets unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",a.projectId),B(this,"projectId",a.projectId),B(this,"projectSecret",a.projectSecret)}isCommunityResource(){return this.projectId===Rs}},Rr=class extends Rt{static getWebSocketProvider(e,t){return new Ps(e,t)}static getApiKey(e){let t={apiKey:Rs,projectId:Rs,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(uu.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),uu.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let a=null;switch(e?e.name:"unknown"){case"homestead":a="mainnet.infura.io";break;case"goerli":a="goerli.infura.io";break;case"sepolia":a="sepolia.infura.io";break;case"matic":a="polygon-mainnet.infura.io";break;case"maticmum":a="polygon-mumbai.infura.io";break;case"optimism":a="optimism-mainnet.infura.io";break;case"optimism-goerli":a="optimism-goerli.infura.io";break;case"arbitrum":a="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":a="arbitrum-goerli.infura.io";break;default:uu.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+a+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===Rs&&ia(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===Rs}};var du=class extends tn{send(e,t){let a={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:a,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:xt(o),provider:this}),Bn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,c)=>{let x=l[c];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Ul=new E(Ee),Yx="ETHERS_JS_SHARED",Ns=class extends Rt{static getApiKey(e){return e&&typeof e!="string"&&Ul.throwArgumentError("invalid apiKey","apiKey",e),e||Yx}static getUrl(e,t){Ul.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let a=null;switch(e.name){case"homestead":a="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":a="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":a="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":a="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":a="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Ul.throwArgumentError("unsupported network","network",arguments[0])}return a+"?apiKey="+t}};var _f=new E(Ee),kf="62e1ad51b37b8e00394bda3b",Ds=class extends Rt{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=kf:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:_f.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let a=null;switch(e?e.name:"unknown"){case"goerli":a="eth-goerli.gateway.pokt.network";break;case"homestead":a="eth-mainnet.gateway.pokt.network";break;case"kovan":a="poa-kovan.gateway.pokt.network";break;case"matic":a="poly-mainnet.gateway.pokt.network";break;case"maticmum":a="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":a="eth-rinkeby.gateway.pokt.network";break;case"ropsten":a="eth-ropsten.gateway.pokt.network";break;default:_f.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${a}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===kf}};var Af=new E(Ee),Xx=1;function Ef(n,e){let t="Web3LegacyFetcher";return function(a,i){let r={method:a,params:i,id:Xx++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:xt(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let c=new Error(p.error.message);return c.code=p.error.code,c.data=p.error.data,o(c)}s(p.result)})})}}function Zx(n){return function(e,t){t==null&&(t=[]);let a={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:xt(a),provider:this}),n.request(a).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:a,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:a,error:i,provider:this}),i})}}var Os=class extends tn{constructor(e,t){e==null&&Af.throwArgumentError("missing provider","provider",e);let a=null,i=null,r=null;typeof e=="function"?(a="unknown:",i=e):(a=e.host||e.path||"",!a&&e.isMetaMask&&(a="metamask"),r=e,e.request?(a===""&&(a="eip-1193:"),i=Zx(e)):e.sendAsync?i=Ef(e,e.sendAsync.bind(e)):e.send?i=Ef(e,e.send.bind(e)):Af.throwArgumentError("unsupported provider","provider",e),a||(a="unknown:")),super(a,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var Mf=new E(Ee);function lu(n,e){if(n==null&&(n="homestead"),typeof n=="string"){let a=n.match(/^(ws|http)s?:/i);if(a)switch(a[1].toLowerCase()){case"http":case"https":return new tn(n);case"ws":case"wss":return new Ea(n);default:Mf.throwArgumentError("unsupported URL scheme","network",n)}}let t=ms(n);return(!t||!t._defaultProvider)&&Mf.throwError("unsupported getDefaultProvider network",E.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:n}),t._defaultProvider({FallbackProvider:Ss,AlchemyProvider:Cr,AnkrProvider:Es,CloudflareProvider:Ms,EtherscanProvider:Is,InfuraProvider:Rr,JsonRpcProvider:tn,NodesmithProvider:Ns,PocketProvider:Ds,Web3Provider:Os,IpcProvider:null},e)}var te={};Ji(te,{AbiCoder:()=>ar,ConstructorFragment:()=>Lt,ErrorFragment:()=>rn,EventFragment:()=>Wt,FormatTypes:()=>Te,Fragment:()=>Kt,FunctionFragment:()=>Ut,HDNode:()=>St,Indexed:()=>fa,Interface:()=>Ba,LogDescription:()=>or,Logger:()=>E,ParamType:()=>ft,RLP:()=>so,SigningKey:()=>Tn,SupportedAlgorithm:()=>na,TransactionDescription:()=>ur,TransactionTypes:()=>Bo,UnicodeNormalizationForm:()=>Jt,Utf8ErrorFuncs:()=>To,Utf8ErrorReason:()=>Vt,_TypedDataEncoder:()=>vt,_fetchData:()=>El,_toEscapedUtf8String:()=>Rd,accessListify:()=>dn,arrayify:()=>j,base58:()=>ga,base64:()=>Fd,checkProperties:()=>Yi,checkResultErrors:()=>Zi,commify:()=>Of,computeAddress:()=>vn,computeHmac:()=>Ta,computePublicKey:()=>os,concat:()=>ce,deepCopy:()=>xt,defaultAbiCoder:()=>ns,defaultPath:()=>va,defineReadOnly:()=>B,dnsEncode:()=>is,entropyToMnemonic:()=>_i,fetchJson:()=>Bn,formatBytes32String:()=>Pd,formatEther:()=>Bf,formatUnits:()=>Vl,getAccountPath:()=>Ec,getAddress:()=>me,getContractAddress:()=>fi,getCreate2Address:()=>Vy,getIcapAddress:()=>Uy,getJsonWalletAddress:()=>vl,getStatic:()=>bt,hashMessage:()=>sr,hexConcat:()=>Et,hexDataLength:()=>Ft,hexDataSlice:()=>Se,hexStripZeros:()=>Td,hexValue:()=>zn,hexZeroPad:()=>he,hexlify:()=>W,id:()=>sn,isAddress:()=>Ly,isBytes:()=>cn,isBytesLike:()=>la,isHexString:()=>ie,isValidMnemonic:()=>Ac,isValidName:()=>Ud,joinSignature:()=>Wr,keccak256:()=>fe,mnemonicToEntropy:()=>vr,mnemonicToSeed:()=>fl,namehash:()=>Oa,nameprep:()=>Bd,parseBytes32String:()=>Nd,parseEther:()=>Ff,parseTransaction:()=>Fo,parseUnits:()=>jl,poll:()=>Fn,randomBytes:()=>aa,recoverAddress:()=>bi,recoverPublicKey:()=>Oo,resolveProperties:()=>Re,ripemd160:()=>ls,serializeTransaction:()=>us,sha256:()=>en,sha512:()=>ll,shallowCopy:()=>_e,shuffled:()=>cs,solidityKeccak256:()=>Sf,solidityPack:()=>pu,soliditySha256:()=>Rf,splitSignature:()=>Gn,stripZeros:()=>nn,toUtf8Bytes:()=>we,toUtf8CodePoints:()=>Da,toUtf8String:()=>Yt,verifyMessage:()=>qc,verifyTypedData:()=>zc,zeroPad:()=>li});var If="solidity/5.7.0";var eb=new RegExp("^bytes([0-9]+)$"),tb=new RegExp("^(u?int)([0-9]*)$"),nb=new RegExp("^(.*)\\[([0-9]*)\\]$"),ab="0000000000000000000000000000000000000000000000000000000000000000",Pr=new E(If);function Cf(n,e,t){switch(n){case"address":return t?li(e,32):j(e);case"string":return we(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?li(e,32):j(e)}let a=n.match(tb);if(a){let i=parseInt(a[2]||"256");return(a[2]&&String(i)!==a[2]||i%8!==0||i===0||i>256)&&Pr.throwArgumentError("invalid number type","type",n),t&&(i=256),e=F.from(e).toTwos(i),li(e,i/8)}if(a=n.match(eb),a){let i=parseInt(a[1]);return(String(i)!==a[1]||i===0||i>32)&&Pr.throwArgumentError("invalid bytes type","type",n),j(e).byteLength!==i&&Pr.throwArgumentError(`invalid value for ${n}`,"value",e),t?j((e+ab).substring(0,66)):e}if(a=n.match(nb),a&&Array.isArray(e)){let i=a[1];parseInt(a[2]||String(e.length))!=e.length&&Pr.throwArgumentError(`invalid array length for ${n}`,"value",e);let s=[];return e.forEach(function(o){s.push(Cf(i,o,!0))}),ce(s)}return Pr.throwArgumentError("invalid type","type",n)}function pu(n,e){n.length!=e.length&&Pr.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return n.forEach(function(a,i){t.push(Cf(a,e[i]))}),W(ce(t))}function Sf(n,e){return fe(pu(n,e))}function Rf(n,e){return en(pu(n,e))}var Pf="units/5.7.0";var Nf=new E(Pf),Df=["wei","kwei","mwei","gwei","szabo","finney","ether"];function Of(n){let e=String(n).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||n==="."||n==="-.")&&Nf.throwArgumentError("invalid value","value",n);let t=e[0],a="";for(t.substring(0,1)==="-"&&(a="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return a+r.join(",")+i}function Vl(n,e){if(typeof e=="string"){let t=Df.indexOf(e);t!==-1&&(e=3*t)}return Qi(n,e??18)}function jl(n,e){if(typeof n!="string"&&Nf.throwArgumentError("value must be a string","value",n),typeof e=="string"){let t=Df.indexOf(e);t!==-1&&(e=3*t)}return mn(n,e??18)}function Bf(n){return Vl(n,18)}function Ff(n){return jl(n,18)}var yu="ethers/5.7.2";var Lf=new E(yu);try{let n=window;n._ethers==null&&(n._ethers=Hl)}catch{}var Ln;(function(n){n.Mainnet="Mainnet",n.Custom="Custom",n.Gnosis="Xdai",n.Goerli="Goerli",n.Xdai="Xdai",n.XdaiQa="XdaiQa"})(Ln||(Ln={}));var cu;(function(n){n.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",n.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",n.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",n.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",n.Custom=""})(cu||(cu={}));var Nr;(function(n){n.Mainnet="https://colony.io/reputation/mainnet",n.Goerli="https://colony.io/reputation/goerli",n.Xdai="https://xdai.colony.io/reputation/xdai",n.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",n.Custom="http://localhost:3000"})(Nr||(Nr={}));var fu;(function(n){n.Mainnet="",n.Goerli="",n.Gnosis="https://xdai.colony.io/metatransaction/xdai",n.Xdai="https://xdai.colony.io/metatransaction/xdai",n.XdaiQa="https://xdai.colony.io/metatransaction/xdai",n.Custom=""})(fu||(fu={}));var ql;(function(n){n.Mainnet="",n.Goerli="",n.Gnosis="https://xdai.colony.io/rpc/",n.Xdai="https://xdai.colony.io/rpc/",n.XdaiQa="https://xdai.colony.io/rpc/",n.Custom=""})(ql||(ql={}));var Bs;(function(n){n.Mainnet=".colony.joincolony.eth",n.Goerli=".colony.joincolony.test",n.Gnosis=".colony.joincolony.colonyxdai",n.Xdai=".colony.joincolony.colonyxdai",n.XdaiQa=".colony.joincolony.colonyxdai",n.Custom=".colony.joincolony.test"})(Bs||(Bs={}));var Fs;(function(n){n.Mainnet=".user.joincolony.eth",n.Goerli=".user.joincolony.test",n.Gnosis=".user.joincolony.colonyxdai",n.Xdai=".user.joincolony.colonyxdai",n.XdaiQa=".user.joincolony.colonyxdai",n.Custom=".user.joincolony.test"})(Fs||(Fs={}));var zl;(function(n){let e;(function(a){a.ETH="0x0000000000000000000000000000000000000000",a.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=n.Mainnet||(n.Mainnet={}));let t;(function(a){a.XDAI="0x0000000000000000000000000000000000000000",a.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=n.Gnosis||(n.Gnosis={}))})(zl||(zl={}));var Ae;(function(n){n[n.RootDomain=1]="RootDomain",n[n.RootTeam=1]="RootTeam",n[n.RootPot=1]="RootPot",n[n.SkillIgnore=0]="SkillIgnore"})(Ae||(Ae={}));var Bt;(function(n){n[n.Null=0]="Null",n[n.Staking=1]="Staking",n[n.Submit=2]="Submit",n[n.Reveal=3]="Reveal",n[n.Closed=4]="Closed",n[n.Finalizable=5]="Finalizable",n[n.Finalized=6]="Finalized",n[n.Failed=7]="Failed"})(Bt||(Bt={}));var Wl="0x12345678",Gl;(function(n){n[n.Unassigned=0]="Unassigned",n[n.Domain=1]="Domain",n[n.Task=2]="Task",n[n.Payment=3]="Payment",n[n.Expenditure=4]="Expenditure"})(Gl||(Gl={}));var Me;(function(n){n[n.Recovery=0]="Recovery",n[n.Root=1]="Root",n[n.Arbitration=2]="Arbitration",n[n.Architecture=3]="Architecture",n[n.ArchitectureSubdomain=4]="ArchitectureSubdomain",n[n.Funding=5]="Funding",n[n.Administration=6]="Administration",n[n.LAST_ROLE=7]="LAST_ROLE"})(Me||(Me={}));var ye;(function(n){n.CoinMachine="CoinMachine",n.EvaluatedExpenditure="EvaluatedExpenditure",n.FundingQueue="FundingQueue",n.IVotingReputation="IVotingReputation",n.OneTxPayment="OneTxPayment",n.ReputationBootstrapper="ReputationBootstrapper",n.StagedExpenditure="StagedExpenditure",n.StakedExpenditure="StakedExpenditure",n.StreamingPayments="StreamingPayments",n.TokenSupplier="TokenSupplier",n.VotingReputation="VotingReputation",n.Whitelist="Whitelist"})(ye||(ye={}));var Kl=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],Ai=class{static createInterface(){return new te.Interface(Kl)}static connect(e,t){return new oe(e,Kl,t)}};be(Ai,"abi",Kl);var Jl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],Ei=class{static createInterface(){return new te.Interface(Jl)}static connect(e,t){return new oe(e,Jl,t)}};be(Ei,"abi",Jl);var Uf=(n,e)=>{throw new Error(`${e}: ${n}`)},$l=n=>n!=null;var{keccak256:rb,toUtf8Bytes:sb}=te,{MaxUint256:ob}=gt;var Dr=n=>te.formatEther(n),Or=n=>te.parseEther(n),pn=n=>Or(n[0]),Ql=n=>{let e=n.reduce((t,a)=>t|1<{let e=F.from(n);return[...Array(Me.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter($l)},Mi=async(n,e,t,a)=>{if(F.from(t).eq(F.from(a)))return ob;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(a),{children:s}=await n.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${a} as a child of ${t}`);return F.from(o)},qa=n=>rb(sb(n));var Br=async(n,e)=>(await Ei.connect(n,e).version()).toNumber(),Yl=(n,e)=>n.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter($l);var{hexDataSlice:Xl}=te,{MaxUint256:ub}=gt,Vf=n=>{let e=Xl(n,0,3),t=F.from(Xl(n,4,35)),a=F.from(Xl(n,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:a}},jf=async(n,e,t,a,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,a))return[F.from(t),ub,r];let o=F.from(Ae.RootDomain);if(!await e.hasUserRole(r,o,a))throw new Error(`${r} does not have the permission ${a} in any parent domain`);let p=await Mi(n,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${a} in any parent domain`);return[o,p,r]},db=async(n,e,t,a,i)=>{let r=await Promise.all(a.map(s=>jf(n,e,t,s,i)));for(let s=0;sArray.isArray(a)?a.length===1?oa(n,e,t,a[0],i):db(n,e,t,a,i):jf(n,e,t,a,i);var{MaxUint256:Hf}=gt,{AddressZero:lb}=gt;async function pb(n,e){let t;try{return t=await n.getCapabilityRoles(te.hexZeroPad(e,4)),mu(t)}catch{return[]}}async function Ls(n,e,t,a,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:c,childSkillIndex:x}=Vf(s),C=Ai.connect(r,a.signer||a.provider),_=await pb(C,p);if(_.includes(Me.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${Ae.RootDomain}`);o=Hf}else{let{skillId:U}=await e.getDomain(c),H=await n.getChildSkillId(U,x);if(H.eq(l))o=Hf;else{let{children:M}=await n.getSkill(l),J=M.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,lb);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:yb}=gt,ua=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,a){this.colony=t,this.network=e;let i=a?.network||Ln.Gnosis;this.endpointUrl=a?.customEndpointUrl||Nr[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,a){let i=await this.getBaseEndpoint(a),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await ua.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,a){let i=await this.getBaseEndpoint(a),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await ua.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await ua.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let c=p+1,x=await this.colony.getDomain(c);return{domainId:c,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,c=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return c&&(p=c?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let a=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${a}/${i}`;return ua.fetchReputation(r)}async getTotalReputation(e,t){let a=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${a}/${i}/${yb}/noProof`,s=await ua.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,a,i=3){let{reputationAmount:r}=await this.getReputation(e,t,a),{reputationAmount:s}=await this.getTotalReputation(e,a);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var At=n=>Array.from(Array(n-1)).map(e=>e+1);var qf=10,cA=At(qf),zf={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},Gf=qf-1;var Wf=6,hA=At(Wf),Kf={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},Jf=Wf-1;var $f=7,gA=At($f),Qf={1:[],2:[],3:[],4:[],5:[],6:[]},Yf=$f-1;var Xf=7,wA=At(Xf),Zf={1:[],2:[],3:[],4:[],5:[],6:[]},em=Xf-1;var tm=4,AA=At(tm),nm={1:[],2:[],3:[]},am=tm-1;var im=5,IA=At(im),rm={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},sm=im-1;var om=2,RA=At(om),um={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},dm=om-1;var lm=4,DA=At(lm),pm={1:[1,2,3],2:[1,2,3],3:[1,2,3]},ym=lm-1;var cm=7,FA=At(cm),fm={1:[],2:[],3:[],4:[],5:[],6:[]},mm=cm-1;var hm=11,VA=At(hm),Zl={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},ep=hm-1;var xm=6,qA=At(xm),bm={1:[],2:[],3:[],4:[],5:[]},gm=xm-1;var Un=(n,e,t)=>{switch(n){case ye.CoinMachine:{let a=zf[e];return!!a&&!a.includes(t)}case ye.EvaluatedExpenditure:{let a=Kf[e];return!!a&&!a.includes(t)}case ye.FundingQueue:{let a=Qf[e];return!!a&&!a.includes(t)}case ye.IVotingReputation:{let a=Zl[e];return!!a&&!a.includes(t)}case ye.OneTxPayment:{let a=Zf[e];return!!a&&!a.includes(t)}case ye.ReputationBootstrapper:{let a=nm[e];return!!a&&!a.includes(t)}case ye.StagedExpenditure:{let a=um[e];return!!a&&!a.includes(t)}case ye.StakedExpenditure:{let a=rm[e];return!!a&&!a.includes(t)}case ye.StreamingPayments:{let a=pm[e];return!!a&&!a.includes(t)}case ye.TokenSupplier:{let a=fm[e];return!!a&&!a.includes(t)}case ye.VotingReputation:{let a=Zl[e];return!!a&&!a.includes(t)}case ye.Whitelist:{let a=bm[e];return!!a&&!a.includes(t)}default:return Uf(n,"Could not find extension with name")}};var Fr={[ye.CoinMachine]:Gf,[ye.EvaluatedExpenditure]:Jf,[ye.FundingQueue]:Yf,[ye.IVotingReputation]:ep,[ye.OneTxPayment]:em,[ye.ReputationBootstrapper]:am,[ye.StagedExpenditure]:dm,[ye.StakedExpenditure]:sm,[ye.StreamingPayments]:ym,[ye.TokenSupplier]:mm,[ye.VotingReputation]:ep,[ye.Whitelist]:gm};var jh=Cn(Tm(),1);var wp=Cn(Lh(),1);var Ne;(function(n){n.DEFAULT="default",n.Annotation="annotation",n.Colony="colony",n.Decision="decision",n.Domain="domain",n.Misc="misc"})(Ne||(Ne={}));var vp=2,Tp;(function(n){n[n.LightPink=0]="LightPink",n[n.Pink=1]="Pink",n[n.Black=2]="Black",n[n.EmeraldGreen=3]="EmeraldGreen",n[n.Blue=4]="Blue",n[n.Yellow=5]="Yellow",n[n.Red=6]="Red",n[n.Green=7]="Green",n[n.Periwinkle=8]="Periwinkle",n[n.Gold=9]="Gold",n[n.Aqua=10]="Aqua",n[n.BlueGrey=11]="BlueGrey",n[n.Purple=12]="Purple",n[n.Orange=13]="Orange",n[n.Magenta=14]="Magenta",n[n.PurpleGrey=15]="PurpleGrey"})(Tp||(Tp={}));var Uh=n=>`Validation error(s): ${n.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,A1=n=>({...n,isWhitelistActivated:n.isWhitelistActivated||!1,colonySafes:n.colonySafes||[],colonyTokens:n.colonyTokens||[],verifiedAddresses:n.verifiedAddresses||[]}),_p=(n,e)=>{let t=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=wp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(n);if(t.success){if(t.data.version!==vp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Ne.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let a=Uh(t.errors);throw new Error(a)};var Vh=(n,e)=>{let t=n===Ne.Colony?A1(e):e,a=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=wp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:n,data:t,version:vp});if(!a.success){let i=Uh(a.errors);throw new Error(i)}return a.data};var kp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},Ap=kp;var Ep=(0,jh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Ws={[Ne.Annotation]:"Annotation(address,bytes32,string)",[Ne.Colony]:"ColonyMetadata(address,string)",[Ne.Decision]:"Annotation(address,bytes32,string)",[Ne.Domain]:"DomainMetadata(address,uint256,string)",[Ne.Misc]:"",[Ne.DEFAULT]:""},Hr=class{adapter;constructor(e){this.adapter=e||new Ap}static eventSupportsMetadata(e){return!!Object.keys(Ws).includes(e)}async getMetadata(e,t){let a=this.adapter.getIpfsUrl(e),r=await(await Ep(a)).json();return _p(r,t)}async getMetadataForEvent(e,t){let a=this.adapter.getIpfsUrl(t),r=await(await Ep(a)).json(),s=Object.entries(Ws).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return _p(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),a=await Ep(t);try{return await a.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let a=Vh(e,t),i=JSON.stringify(a);return this.adapter.uploadJson(i)}};var hM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var Mp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],En=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};be(En,"abi",Mp);var Ip=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Mn=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};be(Mn,"abi",Ip);var Cp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};be(Ni,"abi",Cp);var $u=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Hh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",J1=n=>n.length>1,Vn=class extends Ti{constructor(...e){J1(e)?super(...e):super($u,Hh,e[0])}deploy(e,t,a,i){return super.deploy(e,t,a,i||{})}getDeployTransaction(e,t,a,i){return super.getDeployTransaction(e,t,a,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface($u)}static connect(e,t){return new oe(e,$u,t)}};be(Vn,"bytecode",Hh),be(Vn,"abi",$u);var Sp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Di=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};be(Di,"abi",Sp);var Rp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};be(Oi,"abi",Rp);var Bi;(function(n){n.TokenClient="TokenClient",n.TokenLockingClient="TokenLockingClient"})(Bi||(Bi={}));var In;(function(n){n.Colony="Colony",n.ColonyLegacy="ColonyLegacy",n.Erc20="Erc20",n.Erc2612="Erc2612",n.Sai="Sai"})(In||(In={}));var{AddressZero:qh}=gt;async function Y1(n){try{await n.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var X1=async(n,e)=>{let t,a=!0,i=!0,r=!0;t=Vn.connect(n,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await Y1(t)}catch{a=!1}try{await t.getMetatransactionNonce(qh)}catch{i=!1}try{await t.nonces(qh)}catch{r=!1}return a?i?t.tokenClientType=In.Colony:(t=Di.connect(n,e),t.tokenClientType=In.ColonyLegacy):r?(t=Mn.connect(n,e),t.tokenClientType=In.Erc2612):(t=En.connect(n,e),t.tokenClientType=In.Erc20),t.clientType=Bi.TokenClient,t},Pp=X1;var Z1=(n,e)=>{let t=Oi.connect(n,e);return t.clientType=Bi.TokenLockingClient,t},Np=Z1;var{AddressZero:Dp}=gt,eg=En.connect(Dp,new sa.BaseProvider(3656691)).interface,tg=Ni.connect(Dp,new sa.BaseProvider(3656691)).interface,ng=Mn.connect(Dp,new sa.BaseProvider(3656691)).interface;var Op=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ks=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Ks.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Js=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Js.abi=Bp;var Fp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Fi.abi=Fp;var Ma=class{constructor({colonyNetwork:e,contract:t,method:a,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=a,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let a=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Ws[this.txConfig.metadataType],t.metadata);return[t,e,a]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:a}=t;if(!a)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return a.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Yl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:ig,solidityKeccak256:rg,splitSignature:sg}=te,Li=class extends Ma{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let a=this.colonyNetwork.getSigner(),{provider:i}=a;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Ln.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await a.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=rg(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=ig(l),c=await a.signMessage(p),{r:x,s:C,v:_}=sg(c),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(n,e)=>{if("events"in e&&e.events){let t=e.events.find(a=>a.event===n);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(a=>a.name===n);if(t?.args)return t.args}},Qu=(n,e,t)=>{let a;"events"in e&&e.events?a=e.events:"logs"in e&&e.logs?a=e.logs:a=[];for(let i=0;i{let a=await this.getMotionTx(t);return[a,this.getMotionMined.bind(this,a)]},mined:async()=>{let a=await this.getMotionTx(t);return this.getMotionMined(a)},encode:async()=>{let[a]=await this.getEncodedMotionTx(t);return a}}}metaMotion(t=Ae.RootDomain){return{send:async()=>{let a=await this.getMetaMotionTx(t);return[a,this.getMetaMotionMinded.bind(this,a)]},mined:async()=>{let a=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(a)}}}};var Lp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};Ui.abi=Lp;var Up=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Vi.abi=Up;var Vp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],ji=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};ji.abi=Vp;var jp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};Hi.abi=jp;var Hp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],qi=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};qi.abi=Hp;var qp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],zi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};zi.abi=qp;var{AddressZero:cg}=gt,jn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(qa(jn.extensionType),e.address);if(t===cg)throw new Error(`${jn.extensionType} extension is not installed for this Colony`);let a=await Br(t,e.colonyNetwork.signerOrProvider);if(!Un(jn.extensionType,a,e.version))throw new Error(`Version ${a} of the ${jn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=jn.supportedVersions.find(s=>s.version===a)?.factory;if(!i)throw new Error(`Version ${a} of the ${jn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new jn(e,r,a)}static getLatestSupportedVersion(){return jn.supportedVersions[jn.supportedVersions.length-1]?.version}constructor(e,t,a){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=a}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,a,i){let r=[].concat(e),s=a||Ae.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let c=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await oa(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Me.Administration,Me.Funding],this.oneTxPaymentContract.address),[S,L]=await oa(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Me.Administration,Me.Funding]);return[_,v,S,L,c,C,x,s,Ae.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[qa(ye.OneTxPayment),t],async a=>({...ne("ExtensionUpgraded",a)}))}},Wa=jn;Wa.supportedVersions=[{version:3,factory:Hi},{version:4,factory:qi},{version:5,factory:zi}],Wa.extensionType=ye.OneTxPayment;var Hn=class{constructor(e,t){typeof t=="string"?this.tokenClient=En.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async a=>({...ne("Transfer",a)}))}transferFrom(e,t,a){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,a],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let a=await this.colonyNetwork.getTokenLocking();return[t||a.address,e]},async a=>({...ne("Approval",a)}))}};var $s=class extends Hn{constructor(t,a){super(t,a);typeof a=="string"?this.tokenClient=Vn.connect(a,t.signerOrProvider):this.tokenClient=a,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async a=>({...ne("LogSetAuthority",a)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async a=>({...ne("LogSetOwner",a)}))}};var Qs=class extends Hn{constructor(t,a){super(t,a);typeof a=="string"?this.tokenClient=Mn.connect(a,t.signerOrProvider):this.tokenClient=a,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,a){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[a||i.address,t]},async i=>({...ne("Approval",i)}))}};var zh=async(n,e)=>{let t=await Pp(e,n.signerOrProvider);switch(t.tokenClientType){case In.Colony:return new $s(n,t);case In.Erc20:return new Hn(n,t);case In.Erc2612:return new Qs(n,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var zp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Gi=class{static createInterface(){return new te.Interface(zp)}static connect(e,t){return new oe(e,zp,t)}};Gi.abi=zp;var Gp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Wi=class{static createInterface(){return new te.Interface(Gp)}static connect(e,t){return new oe(e,Gp,t)}};Wi.abi=Gp;var Wp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ki=class{static createInterface(){return new te.Interface(Wp)}static connect(e,t){return new oe(e,Wp,t)}};Ki.abi=Wp;var{AddressZero:Kp}=gt;var Yu=F.from(10).pow(18),qn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(qa(qn.extensionType),e.address);if(t===Kp)throw new Error(`${qn.extensionType} extension is not installed for this Colony`);let a=await Br(t,e.colonyNetwork.signerOrProvider);if(!Un(qn.extensionType,a,e.version))throw new Error(`Version ${a} of the ${qn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=qn.supportedVersions.find(s=>s.version===a)?.factory;if(!i)throw new Error(`Version ${a} of the ${qn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new qn(e,r,a)}static getLatestSupportedVersion(){return qn.supportedVersions[qn.supportedVersions.length-1]?.version}constructor(e,t,a){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=a}async createMotionSalt(e){let{address:t}=this.votingReputationContract,a=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${a}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,a){let{key:i,value:r,branchMask:s,siblings:o}=a,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,a,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,a,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:a,value:i,branchMask:r,siblings:s}=await Ls(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Kp,Wl);return[e,t,Kp,Wl,a,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let a;return typeof t=="string"?a=t:a=await this.colony.colonyNetwork.ipfs.uploadMetadata(Ne.Decision,t),[e,a]},async a=>({...ne("Annotation",a)}),{metadataType:Ne.Decision})}approveStake(e,t=Ae.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async a=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Qu("UserTokenApproved",a,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,a){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==Bt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${Bt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(a))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(a))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(a))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(a).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Dr(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await oa(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,Me.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),a,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let a=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Bt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${Bt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:c,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,c,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",a,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let a=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Bt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${Bt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),c=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,c,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,c,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",a,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let a=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Bt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${Bt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await Mi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:c,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,c,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",a,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let a=await this.votingReputationContract.getMotionState(e);if(a!==Bt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${Bt[a]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async a=>({...ne("MotionFinalized",a)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[qa(ye.VotingReputation),t],async a=>({...ne("ExtensionUpgraded",a)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,a,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:a,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ka=qn;Ka.supportedVersions=[{version:7,factory:Gi},{version:8,factory:Wi},{version:9,factory:Ki}],Ka.extensionType=ye.VotingReputation;var xg={["motion"]:Ka,["oneTx"]:Wa},zr=class{static async connect(e,t){let a=await Br(t,e.signerOrProvider),i=zr.supportedVersions.find(p=>p.version===a)?.factory;if(!i)throw new Error(`Version ${a} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await zh(e,s),l=new zr(e,r,o,a);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return zr.supportedVersions[zr.supportedVersions.length-1].version}constructor(e,t,a,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new ua(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=a,this.version=i}createColonyTxCreator(e,t,a,i,r){return new qr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:a,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,a,i,r,s){return new qr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:a,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ka.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Wa.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Hn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Ne.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Domain,e),[Ae.RootDomain,t]},{roles:Me.Architecture,domain:Ae.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Ne.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[Ae.RootDomain],{roles:Me.Architecture,domain:Ae.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Domain,e),[Ae.RootDomain,t]},{roles:Me.Architecture,domain:Ae.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Ne.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:Me.Architecture,domain:e},async a=>({...ne("DomainDeprecated",a)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async a=>({...ne("ColonyFundsClaimed",a)}))}moveFundsToTeam(e,t,a,i){let r=Ae.RootDomain,s=a||Ae.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,c]=await oa(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,Me.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await Mi(x,this.colony,r,s),_=await Mi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,c,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=Ae.RootDomain,a=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,a)}async getReputationPoints(e,t=Ae.RootDomain){let{skillId:a}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(a,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async a=>({...ne("ArbitraryTransaction",a)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let a;return typeof t=="string"?a=t:a=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Annotation,t),[e,a]},async a=>({...ne("Annotation",a)}),{metadataType:Ne.Annotation})}installExtension(e){let t=xg[e],a=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Un(i,a,this.version))throw new Error(`v${a} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[qa(i),t.getLatestSupportedVersion()],async s=>({...Qu("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=Ae.RootDomain){let a=await this.colony.getUserRoles(e,t);return mu(a)}setRoles(e,t,a=Ae.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,a),r=Array.from(new Set([...i,...[].concat(t)])),s=Ql(r);return[e,a,s]},{roles:Me.Architecture,domain:a},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,a=Ae.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,a)).filter(o=>![].concat(t).includes(o)),s=Ql(r);return[e,a,s]},{roles:Me.Architecture,domain:a},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let a=[],i=await t.getTokenLocking();return e?a=[...e,i]:a=[i],[this.token.address,this.address,a]},async a=>({...ne("TokenAuthorityDeployed",a)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async a=>({...ne("ColonyUpgraded",a)}))}awardReputation(e,t,a=Ae.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[a,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,a=Ae.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[a,e,F.from(0).sub(t)],{domain:a,roles:Me.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Gr=zr;Gr.supportedVersions=[{version:11,factory:Ui},{version:12,factory:Vi},{version:13,factory:ji}];var{splitSignature:bg}=te,Xu=class extends Ma{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,a]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Ln.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),c=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:a,nonce:l.toString(),deadline:c}),{r:C,s:_,v}=bg(x),S={target:e,owner:o,spender:t,value:a.toString(),deadline:c,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Ys=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Np(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async a=>({...ne("UserTokenDeposited",a)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async a=>({...ne("UserTokenWithdrawn",a)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,a){return this.tokenLockingContract.getApproval(t,e,a)}};var{namehash:Gh}=te,{AddressZero:Jp}=gt,Xs=class{constructor(e,t){this.network=t?.network||Ln.Gnosis,this.ipfs=new Hr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||fu[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Nr[this.network]},this.networkContract=Fi.connect(t?.customNetworkAddress||cu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof Nt))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Ys(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,a,i,r){return new Ma({colonyNetwork:this,contract:e,method:t,args:a,eventData:i,txConfig:r})}createMetaTxCreator(e,t,a,i,r){return new Li({colonyNetwork:this,contract:e,method:t,args:a,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,a,i,r){return new Xu({colonyNetwork:this,contract:e,method:t,args:a,eventData:i,txConfig:r})}createColony(e,t,a){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Jp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return a?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof a=="string"?r[6]=a:r[6]=await this.ipfs.uploadMetadata(Ne.Colony,a),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Ne.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Gr.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Bs[this.network],""):null}async getColonyAddress(e){let t=Gh(`${e}${Bs[this.network]}`),a=await this.networkContract.addr(t);return a!==Jp?a:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Fs[this.network],""):null}async getUserAddress(e){let t=Gh(`${e}${Fs[this.network]}`),a=await this.networkContract.addr(t);return a!==Jp?a:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async a=>({...ne("UserLabelRegistered",a)}))}deployToken(e,t,a=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,a],async i=>({...ne("TokenDeployed",i)}))}};var Wh=async n=>{if(!n.ext.oneTx){if(!Un(ye.OneTxPayment,Fr[ye.OneTxPayment],n.version))throw new Error(`OneTxPayment extension of version ${Fr[ye.OneTxPayment]} is not compatible with the installed Colony version ${n.version}`);if(await n.installExtension("oneTx").tx().mined(),await n.updateExtensions(),!n.ext.oneTx)throw new Error("OneTxPayment extension could not be installed");let e=n.ext.oneTx;await n.setRoles(e.address,[Me.Administration,Me.Funding]).tx().mined()}},Kh=async n=>{if(!n.ext.motions){if(!Un(ye.VotingReputation,Fr[ye.VotingReputation],n.version))throw new Error(`VotingReputation extension of version ${Fr[ye.VotingReputation]} is not compatible with the installed Colony version ${n.version}`);if(await n.installExtension("motion").tx().mined(),await n.updateExtensions(),!n.ext.motions)throw new Error("OneTxPayment extension could not be installed");let e=n.ext.motions;await n.setRoles(e.address,[Me.Recovery,Me.Root,Me.Arbitration,Me.Architecture,Me.Funding,Me.Administration]).tx().mined(),await(await e.getInternalVotingReputationContract().initialise(pn`0.01`,pn`0.2`,pn`0.01`,pn`0.7`,6*60,6*60,6*60,6*60)).wait()}};var{isAddress:vg}=te,$p=new sa.JsonRpcProvider("http://127.0.0.1:8545"),ed,Oe,yn,wg=()=>new ln("0x0355596cdb5e5242ad082c4fe3f8bbe48c9dba843fe1f99dd8272f487e70efae",$p),_g=async n=>{let e=wg();ed=new Xs(e,{customNetworkAddress:n,reputationOracleEndpoint:"http://localhost:3000"}),Oe=await ed.getMetaColony()},kg=async()=>{if(await Wh(Oe),await Kh(Oe),Oe=await ed.getMetaColony(),!Oe.ext.oneTx)throw new Error("OneTxPayment extension not installed");await Oe.mint(pn`500`).tx().mined(),await Oe.claimFunds().tx().mined(),await Oe.ext.oneTx.pay("0xb77D57F4959eAfA0339424b83FcFaf9c15407461",pn`100`).tx().mined(),await Oe.ext.oneTx.pay("0x9df24e73f40b2a911eb254a8825103723e13209c",pn`20`).tx().mined()},Ag=async n=>{if(!Oe.ext.motions)throw new Error("VotingReputation extension not installed");if(!Oe.ext.oneTx)throw new Error("OneTxPayment extension not installed");let[{motionId:e}]=await Oe.ext.oneTx.pay("0x27ff0c145e191c22c75cd123c679c3e1f58a4469",Or(n)).motion().mined();if(!e)throw new Error("Could not get motionId from tx");return e},Eg=async n=>{if(!Oe.ext.motions)throw new Error("Motions & Disputes extension not installed");let e=await Oe.ext.motions.getMotion(n);yn=F.from(n);let t=await Oe.ext.motions?.getRemainingStakes(n),a=await Oe.ext.motions.getMotionState(n);return{...e,motionState:Bt[a],remainingStakes:t}},Mg=async()=>{await Oe.token.approve(pn`20`).tx().mined(),await(await ed.getTokenLocking()).deposit(Oe.token.address,pn`20`).tx().mined(),await Oe.ext.motions?.approveStake(pn`20`).tx().mined()},Ig=async n=>{await Oe.ext.motions?.stakeMotion(yn,1,n).tx().mined()},Cg=async n=>{await Oe.ext.motions?.stakeMotion(yn,0,n).tx().mined()},Sg=async()=>{await Oe.ext.motions?.submitVote(yn,1).tx().mined()},Rg=async()=>{await Oe.ext.motions?.submitVote(yn,0).tx().mined()},Pg=async()=>{await Yp(7*60),await Oe.ext.motions?.revealVote(yn).tx().mined()},Ng=async()=>{await Yp(7*60),await Oe.ext.motions?.finalizeMotion(yn).tx().mined()},Yp=async n=>{await $p.send("evm_increaseTime",[n]),await $p.send("evm_mine",[])},Zu=document.querySelector("#address"),Qp=document.querySelector("#payment_amount"),Xp=document.querySelector("#stake_amount"),Jh=document.querySelector("#button_create_motion"),$h=document.querySelector("#motion_id"),Qh=document.querySelector("#button_connect"),Yh=document.querySelector("#button_bootstrap"),Xh=document.querySelector("#button_stake_clny"),Zh=document.querySelector("#button_get_motion"),e6=document.querySelector("#button_jump"),t6=document.querySelector("#button_stake_yay"),n6=document.querySelector("#button_stake_nay"),a6=document.querySelector("#button_vote_yay"),i6=document.querySelector("#button_vote_nay"),r6=document.querySelector("#button_reveal"),s6=document.querySelector("#button_finalize"),Zp=document.querySelector("#error"),o6=document.querySelector("#result");if(!Zu||!Qp||!$h||!Xp||!Zp||!o6||!Qh||!Yh||!Xh||!Jh||!Zh||!e6||!t6||!n6||!a6||!i6||!r6||!s6)throw new Error("Could not find all required HTML elements");var Pt=n=>{Zp.innerText=`Found an error: ${n.message}`,console.error(n)},da=()=>{Zp.innerText=""},ke=n=>{o6.innerText=n};Qh.addEventListener("click",async()=>{da();let n=Zu.value;if(!vg(n))return Pt(new Error("This is not a valid address"));ke("Processing...");try{await _g(Zu.value),ke(` +`)}`,A1=n=>({...n,isWhitelistActivated:n.isWhitelistActivated||!1,colonySafes:n.colonySafes||[],colonyTokens:n.colonyTokens||[],verifiedAddresses:n.verifiedAddresses||[]}),_p=(n,e)=>{let t=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=wp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(n);if(t.success){if(t.data.version!==vp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Ne.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let a=Uh(t.errors);throw new Error(a)};var Vh=(n,e)=>{let t=n===Ne.Colony?A1(e):e,a=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=wp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:n,data:t,version:vp});if(!a.success){let i=Uh(a.errors);throw new Error(i)}return a.data};var kp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},Ap=kp;var Ep=(0,jh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Ws={[Ne.Annotation]:"Annotation(address,bytes32,string)",[Ne.Colony]:"ColonyMetadata(address,string)",[Ne.Decision]:"Annotation(address,bytes32,string)",[Ne.Domain]:"DomainMetadata(address,uint256,string)",[Ne.Misc]:"",[Ne.DEFAULT]:""},Hr=class{adapter;constructor(e){this.adapter=e||new Ap}static eventSupportsMetadata(e){return!!Object.keys(Ws).includes(e)}async getMetadata(e,t){let a=this.adapter.getIpfsUrl(e),r=await(await Ep(a)).json();return _p(r,t)}async getMetadataForEvent(e,t){let a=this.adapter.getIpfsUrl(t),r=await(await Ep(a)).json(),s=Object.entries(Ws).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return _p(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),a=await Ep(t);try{return await a.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let a=Vh(e,t),i=JSON.stringify(a);return this.adapter.uploadJson(i)}};var hM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var Mp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],En=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};be(En,"abi",Mp);var Ip=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Mn=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};be(Mn,"abi",Ip);var Cp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};be(Ni,"abi",Cp);var $u=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Hh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",J1=n=>n.length>1,Vn=class extends Ti{constructor(...e){J1(e)?super(...e):super($u,Hh,e[0])}deploy(e,t,a,i){return super.deploy(e,t,a,i||{})}getDeployTransaction(e,t,a,i){return super.getDeployTransaction(e,t,a,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface($u)}static connect(e,t){return new oe(e,$u,t)}};be(Vn,"bytecode",Hh),be(Vn,"abi",$u);var Sp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Di=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};be(Di,"abi",Sp);var Rp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};be(Oi,"abi",Rp);var Bi;(function(n){n.TokenClient="TokenClient",n.TokenLockingClient="TokenLockingClient"})(Bi||(Bi={}));var In;(function(n){n.Colony="Colony",n.ColonyLegacy="ColonyLegacy",n.Erc20="Erc20",n.Erc2612="Erc2612",n.Sai="Sai"})(In||(In={}));var{AddressZero:qh}=gt;async function Y1(n){try{await n.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var X1=async(n,e)=>{let t,a=!0,i=!0,r=!0;t=Vn.connect(n,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await Y1(t)}catch{a=!1}try{await t.getMetatransactionNonce(qh)}catch{i=!1}try{await t.nonces(qh)}catch{r=!1}return a?i?t.tokenClientType=In.Colony:(t=Di.connect(n,e),t.tokenClientType=In.ColonyLegacy):r?(t=Mn.connect(n,e),t.tokenClientType=In.Erc2612):(t=En.connect(n,e),t.tokenClientType=In.Erc20),t.clientType=Bi.TokenClient,t},Pp=X1;var Z1=(n,e)=>{let t=Oi.connect(n,e);return t.clientType=Bi.TokenLockingClient,t},Np=Z1;var{AddressZero:Dp}=gt,eg=En.connect(Dp,new sa.BaseProvider(3656691)).interface,tg=Ni.connect(Dp,new sa.BaseProvider(3656691)).interface,ng=Mn.connect(Dp,new sa.BaseProvider(3656691)).interface;var Op=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ks=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Ks.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Js=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Js.abi=Bp;var Fp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Fi.abi=Fp;var Ma=class{constructor({colonyNetwork:e,contract:t,method:a,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=a,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let a=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Ws[this.txConfig.metadataType],t.metadata);return[t,e,a]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:a}=t;if(!a)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return a.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Yl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:ig,solidityKeccak256:rg,splitSignature:sg}=te,Li=class extends Ma{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let a=this.colonyNetwork.getSigner(),{provider:i}=a;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Ln.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await a.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=rg(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=ig(l),c=await a.signMessage(p),{r:x,s:C,v:_}=sg(c),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(n,e)=>{if("events"in e&&e.events){let t=e.events.find(a=>a.event===n);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(a=>a.name===n);if(t?.args)return t.args}},Qu=(n,e,t)=>{let a;"events"in e&&e.events?a=e.events:"logs"in e&&e.logs?a=e.logs:a=[];for(let i=0;i{let a=await this.getMotionTx(t);return[a,this.getMotionMined.bind(this,a)]},mined:async()=>{let a=await this.getMotionTx(t);return this.getMotionMined(a)},encode:async()=>{let[a]=await this.getEncodedMotionTx(t);return a}}}metaMotion(t=Ae.RootDomain){return{send:async()=>{let a=await this.getMetaMotionTx(t);return[a,this.getMetaMotionMinded.bind(this,a)]},mined:async()=>{let a=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(a)}}}};var Lp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};Ui.abi=Lp;var Up=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Vi.abi=Up;var Vp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],ji=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};ji.abi=Vp;var jp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};Hi.abi=jp;var Hp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],qi=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};qi.abi=Hp;var qp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],zi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};zi.abi=qp;var{AddressZero:cg}=gt,jn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(qa(jn.extensionType),e.address);if(t===cg)throw new Error(`${jn.extensionType} extension is not installed for this Colony`);let a=await Br(t,e.colonyNetwork.signerOrProvider);if(!Un(jn.extensionType,a,e.version))throw new Error(`Version ${a} of the ${jn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=jn.supportedVersions.find(s=>s.version===a)?.factory;if(!i)throw new Error(`Version ${a} of the ${jn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new jn(e,r,a)}static getLatestSupportedVersion(){return jn.supportedVersions[jn.supportedVersions.length-1]?.version}constructor(e,t,a){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=a}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,a,i){let r=[].concat(e),s=a||Ae.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let c=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await oa(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Me.Administration,Me.Funding],this.oneTxPaymentContract.address),[S,L]=await oa(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Me.Administration,Me.Funding]);return[_,v,S,L,c,C,x,s,Ae.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[qa(ye.OneTxPayment),t],async a=>({...ne("ExtensionUpgraded",a)}))}},Wa=jn;Wa.supportedVersions=[{version:3,factory:Hi},{version:4,factory:qi},{version:5,factory:zi}],Wa.extensionType=ye.OneTxPayment;var Hn=class{constructor(e,t){typeof t=="string"?this.tokenClient=En.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async a=>({...ne("Transfer",a)}))}transferFrom(e,t,a){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,a],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let a=await this.colonyNetwork.getTokenLocking();return[t||a.address,e]},async a=>({...ne("Approval",a)}))}};var $s=class extends Hn{constructor(t,a){super(t,a);typeof a=="string"?this.tokenClient=Vn.connect(a,t.signerOrProvider):this.tokenClient=a,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async a=>({...ne("LogSetAuthority",a)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async a=>({...ne("LogSetOwner",a)}))}};var Qs=class extends Hn{constructor(t,a){super(t,a);typeof a=="string"?this.tokenClient=Mn.connect(a,t.signerOrProvider):this.tokenClient=a,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,a){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[a||i.address,t]},async i=>({...ne("Approval",i)}))}};var zh=async(n,e)=>{let t=await Pp(e,n.signerOrProvider);switch(t.tokenClientType){case In.Colony:return new $s(n,t);case In.Erc20:return new Hn(n,t);case In.Erc2612:return new Qs(n,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var zp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Gi=class{static createInterface(){return new te.Interface(zp)}static connect(e,t){return new oe(e,zp,t)}};Gi.abi=zp;var Gp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Wi=class{static createInterface(){return new te.Interface(Gp)}static connect(e,t){return new oe(e,Gp,t)}};Wi.abi=Gp;var Wp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ki=class{static createInterface(){return new te.Interface(Wp)}static connect(e,t){return new oe(e,Wp,t)}};Ki.abi=Wp;var{AddressZero:Kp}=gt;var Yu=F.from(10).pow(18),qn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(qa(qn.extensionType),e.address);if(t===Kp)throw new Error(`${qn.extensionType} extension is not installed for this Colony`);let a=await Br(t,e.colonyNetwork.signerOrProvider);if(!Un(qn.extensionType,a,e.version))throw new Error(`Version ${a} of the ${qn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=qn.supportedVersions.find(s=>s.version===a)?.factory;if(!i)throw new Error(`Version ${a} of the ${qn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new qn(e,r,a)}static getLatestSupportedVersion(){return qn.supportedVersions[qn.supportedVersions.length-1]?.version}constructor(e,t,a){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=a}async createMotionSalt(e){let{address:t}=this.votingReputationContract,a=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${a}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,a){let{key:i,value:r,branchMask:s,siblings:o}=a,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,a,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,a,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:a,value:i,branchMask:r,siblings:s}=await Ls(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Kp,Wl);return[e,t,Kp,Wl,a,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let a;return typeof t=="string"?a=t:a=await this.colony.colonyNetwork.ipfs.uploadMetadata(Ne.Decision,t),[e,a]},async a=>({...ne("Annotation",a)}),{metadataType:Ne.Decision})}approveStake(e,t=Ae.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async a=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Qu("UserTokenApproved",a,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,a){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==Bt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${Bt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(a))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(a))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(a))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(a).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Dr(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await oa(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,Me.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),a,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let a=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Bt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${Bt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:c,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,c,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",a,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let a=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Bt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${Bt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),c=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,c,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,c,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",a,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let a=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Bt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${Bt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await Mi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:c,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,c,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",a,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let a=await this.votingReputationContract.getMotionState(e);if(a!==Bt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${Bt[a]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async a=>({...ne("MotionFinalized",a)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[qa(ye.VotingReputation),t],async a=>({...ne("ExtensionUpgraded",a)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,a,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:a,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ka=qn;Ka.supportedVersions=[{version:7,factory:Gi},{version:8,factory:Wi},{version:9,factory:Ki}],Ka.extensionType=ye.VotingReputation;var xg={["motion"]:Ka,["oneTx"]:Wa},zr=class{static async connect(e,t){let a=await Br(t,e.signerOrProvider),i=zr.supportedVersions.find(p=>p.version===a)?.factory;if(!i)throw new Error(`Version ${a} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await zh(e,s),l=new zr(e,r,o,a);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return zr.supportedVersions[zr.supportedVersions.length-1].version}constructor(e,t,a,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new ua(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=a,this.version=i}createColonyTxCreator(e,t,a,i,r){return new qr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:a,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,a,i,r,s){return new qr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:a,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ka.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Wa.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Hn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Ne.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Domain,e),[Ae.RootDomain,t]},{roles:Me.Architecture,domain:Ae.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Ne.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[Ae.RootDomain],{roles:Me.Architecture,domain:Ae.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Domain,e),[Ae.RootDomain,t]},{roles:Me.Architecture,domain:Ae.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Ne.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:Me.Architecture,domain:e},async a=>({...ne("DomainDeprecated",a)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async a=>({...ne("ColonyFundsClaimed",a)}))}moveFundsToTeam(e,t,a,i){let r=Ae.RootDomain,s=a||Ae.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,c]=await oa(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,Me.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await Mi(x,this.colony,r,s),_=await Mi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,c,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=Ae.RootDomain,a=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,a)}async getReputationPoints(e,t=Ae.RootDomain){let{skillId:a}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(a,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async a=>({...ne("ArbitraryTransaction",a)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let a;return typeof t=="string"?a=t:a=await this.colonyNetwork.ipfs.uploadMetadata(Ne.Annotation,t),[e,a]},async a=>({...ne("Annotation",a)}),{metadataType:Ne.Annotation})}installExtension(e){let t=xg[e],a=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Un(i,a,this.version))throw new Error(`v${a} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[qa(i),t.getLatestSupportedVersion()],async s=>({...Qu("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=Ae.RootDomain){let a=await this.colony.getUserRoles(e,t);return mu(a)}setRoles(e,t,a=Ae.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,a),r=Array.from(new Set([...i,...[].concat(t)])),s=Ql(r);return[e,a,s]},{roles:Me.Architecture,domain:a},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,a=Ae.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,a)).filter(o=>![].concat(t).includes(o)),s=Ql(r);return[e,a,s]},{roles:Me.Architecture,domain:a},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let a=[],i=await t.getTokenLocking();return e?a=[...e,i]:a=[i],[this.token.address,this.address,a]},async a=>({...ne("TokenAuthorityDeployed",a)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async a=>({...ne("ColonyUpgraded",a)}))}awardReputation(e,t,a=Ae.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[a,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,a=Ae.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[a,e,F.from(0).sub(t)],{domain:a,roles:Me.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Gr=zr;Gr.supportedVersions=[{version:11,factory:Ui},{version:12,factory:Vi},{version:13,factory:ji}];var{splitSignature:bg}=te,Xu=class extends Ma{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,a]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Ln.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),c=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:a,nonce:l.toString(),deadline:c}),{r:C,s:_,v}=bg(x),S={target:e,owner:o,spender:t,value:a.toString(),deadline:c,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Ys=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Np(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async a=>({...ne("UserTokenDeposited",a)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async a=>({...ne("UserTokenWithdrawn",a)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,a){return this.tokenLockingContract.getApproval(t,e,a)}};var{namehash:Gh}=te,{AddressZero:Jp}=gt,Xs=class{constructor(e,t){this.network=t?.network||Ln.Gnosis,this.ipfs=new Hr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||fu[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Nr[this.network]},this.networkContract=Fi.connect(t?.customNetworkAddress||cu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof Nt))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Ys(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,a,i,r){return new Ma({colonyNetwork:this,contract:e,method:t,args:a,eventData:i,txConfig:r})}createMetaTxCreator(e,t,a,i,r){return new Li({colonyNetwork:this,contract:e,method:t,args:a,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,a,i,r){return new Xu({colonyNetwork:this,contract:e,method:t,args:a,eventData:i,txConfig:r})}createColony(e,t,a){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Jp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return a?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof a=="string"?r[6]=a:r[6]=await this.ipfs.uploadMetadata(Ne.Colony,a),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Ne.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Gr.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Bs[this.network],""):null}async getColonyAddress(e){let t=Gh(`${e}${Bs[this.network]}`),a=await this.networkContract.addr(t);return a!==Jp?a:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Fs[this.network],""):null}async getUserAddress(e){let t=Gh(`${e}${Fs[this.network]}`),a=await this.networkContract.addr(t);return a!==Jp?a:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async a=>({...ne("UserLabelRegistered",a)}))}deployToken(e,t,a=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,a],async i=>({...ne("TokenDeployed",i)}))}};var Wh=async n=>{if(!n.ext.oneTx){if(!Un(ye.OneTxPayment,Fr[ye.OneTxPayment],n.version))throw new Error(`OneTxPayment extension of version ${Fr[ye.OneTxPayment]} is not compatible with the installed Colony version ${n.version}`);if(await n.installExtension("oneTx").tx().mined(),await n.updateExtensions(),!n.ext.oneTx)throw new Error("OneTxPayment extension could not be installed");let e=n.ext.oneTx;await n.setRoles(e.address,[Me.Administration,Me.Funding]).tx().mined()}},Kh=async n=>{if(!n.ext.motions){if(!Un(ye.VotingReputation,Fr[ye.VotingReputation],n.version))throw new Error(`VotingReputation extension of version ${Fr[ye.VotingReputation]} is not compatible with the installed Colony version ${n.version}`);if(await n.installExtension("motion").tx().mined(),await n.updateExtensions(),!n.ext.motions)throw new Error("OneTxPayment extension could not be installed");let e=n.ext.motions;await n.setRoles(e.address,[Me.Recovery,Me.Root,Me.Arbitration,Me.Architecture,Me.Funding,Me.Administration]).tx().mined(),await(await e.getInternalVotingReputationContract().initialise(pn`0.01`,pn`0.2`,pn`0.01`,pn`0.7`,6*60,6*60,6*60,6*60)).wait()}};var{isAddress:vg}=te,$p=new sa.JsonRpcProvider("http://127.0.0.1:8545"),ed,Oe,yn,wg=()=>new ln("0x0355596cdb5e5242ad082c4fe3f8bbe48c9dba843fe1f99dd8272f487e70efae",$p),_g=async n=>{let e=wg();ed=new Xs(e,{customNetworkAddress:n,reputationOracleEndpoint:"http://localhost:3000"}),Oe=await ed.getMetaColony()},kg=async()=>{if(await Wh(Oe),await Kh(Oe),Oe=await ed.getMetaColony(),!Oe.ext.oneTx)throw new Error("OneTxPayment extension not installed");await Oe.mint(pn`500`).tx().mined(),await Oe.claimFunds().tx().mined(),await Oe.ext.oneTx.pay("0xb77D57F4959eAfA0339424b83FcFaf9c15407461",pn`100`).tx().mined(),await Oe.ext.oneTx.pay("0x9df24e73f40b2a911eb254a8825103723e13209c",pn`20`).tx().mined()},Ag=async n=>{if(!Oe.ext.motions)throw new Error("VotingReputation extension not installed");if(!Oe.ext.oneTx)throw new Error("OneTxPayment extension not installed");let[{motionId:e}]=await Oe.ext.oneTx.pay("0x27ff0c145e191c22c75cd123c679c3e1f58a4469",Or(n)).motion().mined();if(!e)throw new Error("Could not get motionId from tx");return e},Eg=async n=>{if(!Oe.ext.motions)throw new Error("Motions & Disputes extension not installed");let e=await Oe.ext.motions.getMotion(n);yn=F.from(n);let t=await Oe.ext.motions?.getRemainingStakes(n),a=await Oe.ext.motions.getMotionState(n);return{...e,motionState:Bt[a],remainingStakes:t}},Mg=async()=>{await Oe.token.approve(pn`20`).tx().mined(),await(await ed.getTokenLocking()).deposit(Oe.token.address,pn`20`).tx().mined(),await Oe.ext.motions?.approveStake(pn`20`).tx().mined()},Ig=async n=>{await Oe.ext.motions?.stakeMotion(yn,1,n).tx().mined()},Cg=async n=>{await Oe.ext.motions?.stakeMotion(yn,0,n).tx().mined()},Sg=async()=>{await Oe.ext.motions?.submitVote(yn,1).tx().mined()},Rg=async()=>{await Oe.ext.motions?.submitVote(yn,0).tx().mined()},Pg=async()=>{await Yp(7*60),await Oe.ext.motions?.revealVote(yn).tx().mined()},Ng=async()=>{await Yp(7*60),await Oe.ext.motions?.finalizeMotion(yn).tx().mined()},Yp=async n=>{await $p.send("evm_increaseTime",[n]),await $p.send("evm_mine",[])},Zu=document.querySelector("#address"),Qp=document.querySelector("#payment_amount"),Xp=document.querySelector("#stake_amount"),Jh=document.querySelector("#button_create_motion"),$h=document.querySelector("#motion_id"),Qh=document.querySelector("#button_connect"),Yh=document.querySelector("#button_bootstrap"),Xh=document.querySelector("#button_stake_clny"),Zh=document.querySelector("#button_get_motion"),e6=document.querySelector("#button_jump"),t6=document.querySelector("#button_stake_yay"),n6=document.querySelector("#button_stake_nay"),a6=document.querySelector("#button_vote_yay"),i6=document.querySelector("#button_vote_nay"),r6=document.querySelector("#button_reveal"),s6=document.querySelector("#button_finalize"),Zp=document.querySelector("#error"),o6=document.querySelector("#result");if(!Zu||!Qp||!$h||!Xp||!Zp||!o6||!Qh||!Yh||!Xh||!Jh||!Zh||!e6||!t6||!n6||!a6||!i6||!r6||!s6)throw new Error("Could not find all required HTML elements");var Pt=n=>{Zp.innerText=`Found an error: ${n.message}`,console.error(n)},da=()=>{Zp.innerText=""},ke=n=>{o6.innerText=n};Qh.addEventListener("click",async()=>{da();let n=Zu.value;if(!vg(n))return Pt(new Error("This is not a valid address"));ke("Processing...");try{await _g(Zu.value),ke(` Connected to Colony with address: ${Oe.address}. Colony version: ${Oe.version}. `)}catch(e){Pt(e),ke("")}finally{Zu.value=""}return null});Yh.addEventListener("click",async()=>{da(),ke("Processing...");try{await kg()}catch(n){Pt(n),ke("")}ke("Everything was set up successfully. You may now proceed. Remember, this is only necessary once for this example (even after reload)")});Xh.addEventListener("click",async()=>{da(),ke("Processing...");try{await Mg()}catch(n){Pt(n),ke("")}ke("Successfully approved tokens for use in staking")});Jh.addEventListener("click",async()=>{da(),ke("Processing...");try{let n=Qp.value,e=await Ag(n);ke(`Motion created! Motion ID is: ${e}`)}catch(n){Pt(n),ke("")}finally{Qp.value=""}return null});Zh.addEventListener("click",async()=>{let n=$h.value;ke("Processing...");try{let{domainId:e,altTarget:t,action:a,motionState:i,remainingStakes:r}=await Eg(n),s={domainId:e.toString(),altTarget:t,action:a,motionState:i,remainingYayStakes:Dr(r.remainingToFullyYayStaked),remainingNayStakes:Dr(r.remainingToFullyNayStaked)};ke(JSON.stringify(s))}catch(e){Pt(e),ke("")}});e6.addEventListener("click",async()=>{await Yp(3600),ke("Whooo that was a hell of a ride. Welcome to the future")});t6.addEventListener("click",async()=>{if(da(),!yn){Pt(new Error("Please get a motion first (in the previous step) to stake for"));return}ke("Processing...");let n=Or(Xp.value);try{await Ig(n)}catch(e){Pt(e),ke("");return}ke("Staked! Feel free to refresh the motion to see the new values")});n6.addEventListener("click",async()=>{if(da(),!yn){Pt(new Error("Please get a motion first (in the previous step) to stake for"));return}ke("Processing...");let n=Or(Xp.value);try{await Cg(n)}catch(e){Pt(e),ke("");return}ke("Staked! Feel free to refresh the motion to see the new values")});a6.addEventListener("click",async()=>{if(da(),!yn){Pt(new Error("Please get a motion first (in the previous step) to stake for"));return}ke("Processing...");try{await Sg()}catch(n){Pt(n),ke("");return}ke("Voted yay!")});i6.addEventListener("click",async()=>{if(da(),!yn){Pt(new Error("Please get a motion first (in the previous step) to stake for"));return}ke("Processing...");try{await Rg()}catch(n){Pt(n),ke("");return}ke("Voted nay!")});r6.addEventListener("click",async()=>{if(da(),!yn){Pt(new Error("Please get a motion first (in the previous step) to stake for"));return}ke("Processing...");try{await Pg()}catch(n){Pt(n),ke("");return}ke("Vote successfully revealed!")});s6.addEventListener("click",async()=>{if(da(),!yn){Pt(new Error("Please get a motion first (in the previous step) to stake for"));return}ke("Processing...");try{await Ng()}catch(n){Pt(n),ke("");return}ke("Motion was successfully finailzed. The action was executed and rewards are paid out")});})(); diff --git a/local-reputation.js b/local-reputation.js index c6beae64e..770ca9da0 100644 --- a/local-reputation.js +++ b/local-reputation.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),Q5)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var X5="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",rs=null;function bf(a){if(rs==null&&(rs=X5.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),xn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw rs=null,new Error("BIP39 Wordlist for en (English) FAILED")}var ll=class extends xn{constructor(){super("en")}getWord(e){return bf(this),rs[e]}getWordIndex(e){return bf(this),rs.indexOf(e)}},pl=new ll;xn.register(pl);var xi={en:pl};var gf="hdnode/5.7.0";var ss=new E(gf),Y5=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),Z5=we("Bitcoin seed"),hr=2147483648;function vf(a){return(1<=256)throw new Error("Depth too large!");return Tf(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,he(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new It(mr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~hr));let n=new Uint8Array(37);if(e&hr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(ma(Xn.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=Lo(F.from(r).add(this.privateKey).mod(Y5)):l=new mn(W(r))._addPoint(this.publicKey);let p=t,f=this.mnemonic;return f&&(p=Object.freeze({phrase:f.phrase,path:t,locale:f.locale||"en"})),new It(mr,o,l,this.fingerprint,Lo(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=hr)throw new Error("invalid path index - "+r);n=n._derive(hr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=hr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(ma(Xn.sha512,Z5,n));return new It(mr,Lo(i.slice(0,32)),null,"0x00000000",Lo(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=yl(n),e=bi(xr(e,n),n),It._fromSeed(fl(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return It._fromSeed(e,null)}static fromExtendedKey(e){let t=ca.decode(e);(t.length!==82||Tf(t.slice(0,78))!==e)&&ss.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new It(mr,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new It(mr,W(o.slice(1)),null,i,s,r,n,null)}return ss.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function fl(a,e){e||(e="");let t=we("mnemonic"+e,Gt.NFKD);return hi(we(a,Gt.NFKD),t,2048,64,"sha512")}function xr(a,e){e=yl(e),ss.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=vf(s);if((j(Xt(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function bi(a,e){if(e=yl(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&ex(8-n)),n+=3);let i=a.length/4,r=j(Xt(a))[0]&vf(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function wf(a,e){try{return xr(a,e),!0}catch{}return!1}function _f(a){return(typeof a!="number"||a<0||a>=hr||a%1)&&ss.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var kf="random/5.7.0";var cl=new E(kf);function tx(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var Af=tx(),Uo=Af.crypto||Af.msCrypto;(!Uo||!Uo.getRandomValues)&&(cl.warn("WARNING: Missing strong random number source"),Uo={getRandomValues:function(a){return cl.throwError("no secure random source avaialble",E.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Yn(a){(a<=0||a>1024||a%1||a!=a)&&cl.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Uo.getRandomValues(e),j(e)}function os(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var xl=kn(hl());var Vo="json-wallets/5.7.0";function xa(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function br(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),M=new ba.default.Counter(x),J=new ba.default.ModeOfOperation.ctr(O,M),$=j(J.encrypt(i)),de=fe(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:Mf(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(f).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=Yn(16),N=new ba.default.Counter(R),q=new ba.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+br(I.getUTCMonth()+1,2)+"-"+br(I.getUTCDate(),2)+"T"+br(I.getUTCHours(),2)+"-"+br(I.getUTCMinutes(),2)+"-"+br(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function Bf(a,e,t){if(jo(a)){t&&t(0);let n=gl(a,e);return t&&t(1),Promise.resolve(n)}return Ho(a)?Of(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function Ff(a,e){if(jo(a))return gl(a,e);if(Ho(a))return Df(a,e);throw new Error("invalid JSON wallet")}var Lf="wallet/5.7.0";var Uf=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},gr=new E(Lf);function sx(a){return a!=null&&ie(a.privateKey,32)&&a.address!=null}function ox(a){let e=a.mnemonic;return e&&e.phrase}var on=class extends St{constructor(e,t){if(super(),sx(e)){let n=new mn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",hn(this.publicKey)),this.address!==ce(e.address)&&gr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),ox(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||ha,locale:i.locale||"en"}));let r=this.mnemonic,s=It.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);hn(s.privateKey)!==this.address&&gr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(mn.isSigningKey(e))e.curve!=="secp256k1"&&gr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new mn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",hn(this.publicKey))}t&&!$t.isProvider(t)&&gr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new on(this,e)}signTransaction(e){return Ce(e).then(t=>{t.from!=null&&(ce(t.from)!==this.address&&gr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(fe(ns(t)));return ns(t,n)})}signMessage(e){return Uf(this,void 0,void 0,function*(){return Vr(this._signingKey().signDigest(nr(e)))})}_signTypedData(e,t,n){return Uf(this,void 0,void 0,function*(){let i=yield gt.resolveNames(e,t,n,r=>(this.provider==null&&gr.throwError("cannot resolve ENS names without a provider",E.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return Vr(this._signingKey().signDigest(gt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),kl(this,e,t,n)}static createRandom(e){let t=Yn(16);e||(e={}),e.extraEntropy&&(t=j(Ie(fe(ye([t,e.extraEntropy])),0,16)));let n=bi(t,e.locale);return on.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return Bf(e,t,n).then(i=>new on(i))}static fromEncryptedJsonSync(e,t){return new on(Ff(e,t))}static fromMnemonic(e,t,n){return t||(t=ha),new on(It.fromMnemonic(e,null,n).derivePath(t))}};function Vf(a,e){return fi(nr(a),e)}function jf(a,e,t,n){return fi(gt.hash(a,e,t),n)}var ta={};Gi(ta,{AlchemyProvider:()=>Ar,AlchemyWebSocketProvider:()=>gs,AnkrProvider:()=>Ts,BaseProvider:()=>ea,CloudflareProvider:()=>vs,EtherscanProvider:()=>ws,FallbackProvider:()=>ks,Formatter:()=>Y,InfuraProvider:()=>Mr,InfuraWebSocketProvider:()=>Es,IpcProvider:()=>Fl,JsonRpcBatchProvider:()=>iu,JsonRpcProvider:()=>Yt,JsonRpcSigner:()=>_r,NodesmithProvider:()=>Ms,PocketProvider:()=>Is,Provider:()=>$t,Resolver:()=>wr,StaticJsonRpcProvider:()=>bs,UrlJsonRpcProvider:()=>Ct,Web3Provider:()=>Cs,WebSocketProvider:()=>va,getDefaultProvider:()=>ru,getNetwork:()=>ds,isCommunityResourcable:()=>Ml,isCommunityResource:()=>ys,showThrottleMessage:()=>Zn});var Hf="networks/5.7.1";var qf=new E(Hf);function ux(a){return a&&typeof a.renetwork=="function"}function ga(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return ga(t)},e}function zo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return zo(a,n)},t}var Gf={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:ga("homestead")},zf={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:ga("ropsten")},Wf={chainId:63,name:"classicMordor",_defaultProvider:zo("https://www.ethercluster.com/mordor","classicMordor")},Go={unspecified:{chainId:0,name:"unspecified"},homestead:Gf,mainnet:Gf,morden:{chainId:2,name:"morden"},ropsten:zf,testnet:zf,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:ga("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:ga("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:ga("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:ga("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:zo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Wf,classicTestnet:Wf,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:zo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:ga("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:ga("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ds(a){if(a==null)return null;if(typeof a=="number"){for(let n in Go){let i=Go[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=Go[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=Go[a.name];if(!e)return typeof a.chainId!="number"&&qf.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&qf.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(ux(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Kf="web/5.7.1";var dx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Jf(a,e){return dx(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var lx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Sn=new E(Kf);function $f(a){return new Promise(e=>{setTimeout(e,a)})}function Ba(a,e){if(a==null)return null;if(typeof a=="string")return a;if(ra(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Jt(a)}catch{}return W(a)}return a}function px(a){return we(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function Al(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Sn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Sn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},f=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Sn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(f=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Sn.throwError("basic authentication requires a secure https url",E.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+tr(we(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?er(_[3]):px(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Sn.throwError("processing response error",E.errors.SERVER_ERROR,{body:Ba(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(M,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Sn.makeError("timeout",E.errors.TIMEOUT,{requestBody:Ba(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return lx(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Sn.throwError("bad response",E.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Ba(H,U.headers?U.headers["content-type"]:null),requestBody:Ba(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let M=yield t(H,U);return S.cancel(),M}catch(M){if(M.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Jt(r))}catch(l){Sn.throwError("invalid JSON",E.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=we(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return Al(a,i,n)}function Pn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(f){if(f!==void 0)s()&&t(f);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(f){s()&&n(f)})}p()})}var Rl=kn(Zf());var Ae="providers/5.7.2";var ps=new E(Ae),Y=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),f=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:Y.allowNull(this.accessList.bind(this),null),blockHash:Y.allowNull(s,null),blockNumber:Y.allowNull(l,null),transactionIndex:Y.allowNull(l,null),confirmations:Y.allowNull(l,null),from:t,gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),gasLimit:n,to:Y.allowNull(t,null),value:n,nonce:l,data:r,r:Y.allowNull(this.uint256),s:Y.allowNull(this.uint256),v:Y.allowNull(l),creates:Y.allowNull(t,null),raw:Y.allowNull(r)},e.transactionRequest={from:Y.allowNull(t),nonce:Y.allowNull(l),gasLimit:Y.allowNull(n),gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),to:Y.allowNull(t),value:Y.allowNull(n),data:Y.allowNull(f),type:Y.allowNull(l),accessList:Y.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:Y.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:Y.allowNull(this.address,null),from:Y.allowNull(this.address,null),contractAddress:Y.allowNull(t,null),transactionIndex:l,root:Y.allowNull(o),gasUsed:n,logsBloom:Y.allowNull(r),blockHash:s,transactionHash:s,logs:Y.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:Y.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:Y.allowNull(n),status:Y.allowNull(l),type:p},e.block={hash:Y.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:Y.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:Y.allowNull(t),extraData:r,transactions:Y.allowNull(Y.arrayOf(s)),baseFeePerGas:Y.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=Y.allowNull(Y.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:Y.allowNull(i,void 0),toBlock:Y.allowNull(i,void 0),blockHash:Y.allowNull(s,void 0),address:Y.allowNull(t,void 0),topics:Y.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:Y.allowNull(l),blockHash:Y.allowNull(s),transactionIndex:l,removed:Y.allowNull(this.boolean.bind(this)),address:t,data:Y.allowFalsish(r,"0x"),topics:Y.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return sn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():ps.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ce(e)}callAddress(e){if(!ie(e,32))return null;let t=ce(Ie(e,12));return t===lo?null:t}contractAddress(e){return di(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return Un(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Nt(n)!==32?ps.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return he(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=Y.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return Y.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=Y.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ie(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ie(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return Po(e)}receiptLog(e){return Y.check(this.formats.receiptLog,e)}receipt(e){let t=Y.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&ps.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):ps.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&ps.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return Y.check(this.formats.filter,e)}filterLog(e){return Y.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function Ml(a){return a&&typeof a.isCommunityResource=="function"}function ys(a){return Ml(a)&&a.isCommunityResource()}var ec=!1;function Zn(){ec||(ec=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},xe=new E(Ae),gx=10;function tc(a){return a==null?"null":(Nt(a)!==32&&xe.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function nc(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[tc(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return tc(e)}).join("&")}function Tx(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function vr(a){if(typeof a=="string"){if(a=a.toLowerCase(),Nt(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+nc(a);if(vo.isForkEvent(a))throw xe.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+nc(a.topics||[])}throw new Error("invalid event - "+a)}function fs(){return new Date().getTime()}function ac(a){return new Promise(e=>{setTimeout(e,a)})}var vx=["block","network","pending","poll"],Pl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=Tx(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||vx.indexOf(this.tag)>=0}},wx={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Il(a){return he(F.from(a).toHexString(),32)}function ic(a){return ca.encode(ye([a,Ie(Xt(Xt(a)),0,4)]))}var oc=new RegExp("^(ipfs)://(.*)$","i"),rc=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),oc,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function $o(a,e){try{return Jt(cs(a,e))}catch{}return null}function cs(a,e){if(a==="0x")return null;let t=F.from(Ie(a,e,e+32)).toNumber(),n=F.from(Ie(a,t,t+32)).toNumber();return Ie(a,t+32,t+32+n)}function Cl(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):xe.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function sc(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function _x(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function uc(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===E.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:kt([e,Sa(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=kt(["0x9061b923",uc([Yr(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&xe.throwError("resolver threw error",E.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=cs(r,0)),r}catch(r){if(r.code===E.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?cs(n,0):null})}_getAddress(e,t){let n=wx[String(e)];if(n==null&&xe.throwError(`unsupported coin type: ${e}`,E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return ic(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return ic(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=Rl.default.toWords(i.slice(2));return o.unshift(s),Rl.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===Yi?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===E.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",Il(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&xe.throwError("invalid or unsupported coin data",E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return xe.throwError("invalid or unsupported content hash data",E.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=we(e);t=ye([Il(64),Il(t.length),t]),t.length%32!==0&&(t=ye([t,he("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Jt(n)})}},Sl=null,kx=1,ea=class extends $t{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=ht(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):xe.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||xe.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Pn(()=>this._ready().then(e=>e,e=>{if(!(e.code===E.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return Sl==null&&(Sl=new Y),Sl}static getNetwork(e){return ds(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Rn({url:p,errorPassThrough:!0},f,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return xe.throwError(`response not found during CCIP fetch: ${C}`,E.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return xe.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,E.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(fs()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=fs(),n=Ce({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=fs();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=kx++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)xe.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",xe.makeError("network block skew detected",E.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return xe.throwError("provider does not support network detection",E.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield ac(0),this._network;let n=xe.makeError("underlying network changed",E.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=fs();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,f=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield ac(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{f()||o(xe.makeError("timeout exceeded",E.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Un(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return xe.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Nt(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&xe.throwError("Transaction hash mismatch from Provider.sendTransaction.",E.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&xe.throwError("transaction failed",E.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Ce(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Ce(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=gx&&xe.throwError("CCIP read exceeded maximum redirections",E.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Nt(r)%32===4)try{let s=Ie(r,4),o=Ie(s,0,32);F.from(o).eq(i)||xe.throwError("CCIP Read sender did not match",E.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ie(s,32,64)).toNumber(),f=F.from(Ie(s,p,p+32)).toNumber(),x=Ie(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Ce({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),Y.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&xe.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new wr(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||xe.throwError("network does not support ENS",E.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Sa(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ie(e))throw n}typeof e!="string"&&xe.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=$o(yield this.call({to:n,data:"0x691f3431"+Sa(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new wr(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o}try{let o=$o(yield this.call({to:s,data:"0x691f3431"+Sa(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return xe.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new Pl(vr(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=vr(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=vr(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=vr(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=vr(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=vr(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var Ta=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Et=new E(Ae),Ax=["call","estimateGas"];function hs(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ie(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=hs(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return hs(JSON.parse(a),e)}catch{}return null}function lc(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=hs(e,!0);if(r)return r.data;Et.throwError("missing revert data in call exception; Transaction reverted without a reason string",E.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=hs(e.body,!1);r==null&&(r=hs(e,!1)),r&&Et.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===E.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Et.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Et.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Et.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Et.throwError("legacy pre-eip-155 transactions not supported",E.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),Ax.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Et.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function dc(a){return new Promise(function(e){setTimeout(e,a)})}function Ex(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function ms(a){return a&&a.toLowerCase()}var Nl={},_r=class extends St{constructor(e,t,n){if(super(),e!==Nl)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Et.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Et.throwError("cannot alter JSON-RPC Signer connection",E.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new Dl(Nl,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Et.throwError("unknown account #"+this._index,E.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>Ta(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Et.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Ce({tx:Ce(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Et.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Et.throwError("user rejected transaction",E.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),lc("sendTransaction",s,r)))})}signTransaction(e){return Et.throwError("signing transactions is unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return Ta(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Pn(()=>Ta(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return Ta(this,void 0,void 0,function*(){let t=typeof e=="string"?we(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Et.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return Ta(this,void 0,void 0,function*(){let t=typeof e=="string"?we(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Et.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return Ta(this,void 0,void 0,function*(){let i=yield gt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(gt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Et.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return Ta(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},Dl=class extends _r{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},Mx={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},Yt=class extends ea{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=ht(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return Ta(this,void 0,void 0,function*(){yield dc(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=ht(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Et.throwError("could not detect network",E.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Et.throwError("could not detect network",E.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new _r(Nl,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:mt(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Rn(this.connection,JSON.stringify(n),Ex).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ms(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ms(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ms(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ms(t.address),he(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=ht(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=ht(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=ms(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return Ta(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Et.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return lc(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return dc(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(Mx);if(t)for(let r in t)t[r]&&(n[r]=!0);Ki(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Un(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=sn(e.accessList)),i}};var kr=null;try{if(kr=WebSocket,kr==null)throw new Error("inject please")}catch{let e=new E(Ae);kr=function(){e.throwError("WebSockets not supported in this environment",E.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var Ol=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Qo=new E(Ae),Ix=1,va=class extends Yt{constructor(e,t){t==="any"&&Qo.throwError("WebSocketProvider does not support 'any' network yet",E.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new kr(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){Qo.throwError("cannot reset events block on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){Qo.throwError("cannot set polling interval on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return Ol(this,void 0,void 0,function*(){return null})}set polling(e){!e||Qo.throwError("cannot set polling on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=Ix++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return Ol(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return Ol(this,void 0,void 0,function*(){this.websocket.readyState===kr.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var Cx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},xs=new E(Ae),bs=class extends Yt{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return Cx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||xs.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Ct=class extends bs{constructor(e,t){xs.checkAbstract(new.target,Ct),e=ht(new.target,"getNetwork")(e),t=ht(new.target,"getApiKey")(t);let n=ht(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){xs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return xs.throwError("API provider does not support signing",E.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return xs.throwError("not implemented; sub-classes must override getUrl",E.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var pc=new E(Ae),Xo="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",gs=class extends va{constructor(e,t){let n=new Ar(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===Xo}},Ar=class extends Ct{static getWebSocketProvider(e,t){return new gs(e,t)}static getApiKey(e){return e==null?Xo:(e&&typeof e!="string"&&pc.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:pc.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===Xo&&Zn(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===Xo}};var Sx=new E(Ae),Yo="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function Rx(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return Sx.throwArgumentError("unsupported network","name",a)}var Ts=class extends Ct{isCommunityResource(){return this.apiKey===Yo}static getApiKey(e){return e??Yo}static getUrl(e,t){t==null&&(t=Yo);let n={allowGzip:!0,url:"https://"+Rx(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===Yo&&Zn(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var Px=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},yc=new E(Ae),vs=class extends Ct{static getApiKey(e){return e!=null&&yc.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:yc.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return Px(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var Zo=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Fa=new E(Ae);function fc(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Un(W(n)):t==="accessList"?n="["+sn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function Nx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function cc(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function mc(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function Bl(a,e,t){if(a==="call"&&e.code===E.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Fa.throwError("missing revert data in call exception",E.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===E.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Fa.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Fa.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Fa.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Fa.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var ws=class extends ea{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Fa.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return Zo(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?cc:Nx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(f,x)=>(this.isCommunityResource()&&Zn(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(f=>`${f}=${r[f]}`).join("&"));let p=yield Rn(o,l,s||cc);return this.emit("debug",{action:"response",request:i,response:mt(p),provider:this}),p})}detectNetwork(){return Zo(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return Zo(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Bl("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=fc(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Bl("call",r,t.transaction)}}case"estimateGas":{let i=fc(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Bl("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=mc(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=mc(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Fa.throwError("unsupported topic count",E.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Fa.throwError("unsupported topic format",E.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var nu=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},gi=new E(Ae);function eu(){return new Date().getTime()}function hc(a){let e=null;for(let t=0;te?null:(n+i)/2}function Er(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>Er(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=Er(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var Dx=1;function bc(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var Ox=[E.errors.CALL_EXCEPTION,E.errors.INSUFFICIENT_FUNDS,E.errors.NONCE_EXPIRED,E.errors.REPLACEMENT_UNDERPRICED,E.errors.UNPREDICTABLE_GAS_LIMIT],Bx=["address","args","errorArgs","errorSignature","method","transaction"];function tu(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function Fx(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function Lx(a,e,t){let n=Er;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=xc(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return xc(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,Er(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),Er(i))}:n=function(i){return i==null?null:Er(i)};break;default:throw new Error("unknown method: "+e)}return Fx(n,a.quorum)}function _s(a,e){return nu(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Pn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function Ux(a,e,t,n){return nu(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ie(n.blockTag)&&(i=yield _s(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ie(n.blockTag)&&(i=yield _s(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ie(n.blockTag)&&(i=yield _s(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ie(n.blockTag)&&(i=yield _s(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield _s(a,e)),i.getLogs(r)}}return gi.throwError("unknown method error",E.errors.UNKNOWN_ERROR,{method:t,params:n})})}var ks=class extends ea{constructor(e,t){e.length===0&&gi.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if($t.isProvider(s)){let f=ys(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:f,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=ys(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&gi.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&gi.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=hc(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return nu(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return hc(e)})}perform(e,t){return nu(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(f=>f.hash,f=>f)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=eu(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=Ux(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:tu(_,eu()),request:{method:e,params:mt(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:tu(_,eu()),request:{method:e,params:mt(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:tu(_,null),request:{method:e,params:mt(t)},provider:this}),p+=_.weight}let f=[];i.forEach(_=>{_.done||!_.runner||(f.push(_.runner),_.staller&&f.push(_.staller.getPromise()))}),f.length&&(yield Promise.race(f));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield bc(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return Ox.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};Bx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),gi.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),gi.throwError("failed to meet quorum",E.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>tu(l)),provider:this})})}};var Fl=null;var au=new E(Ae),As="84842078b09946638c03157f83405213",Es=class extends va{constructor(e,t){let n=new Mr(e,t),i=n.connection;i.password&&au.throwError("INFURA WebSocket project secrets unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===As}},Mr=class extends Ct{static getWebSocketProvider(e,t){return new Es(e,t)}static getApiKey(e){let t={apiKey:As,projectId:As,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(au.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),au.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:au.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===As&&Zn(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===As}};var iu=class extends Yt{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:mt(o),provider:this}),Rn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,f)=>{let x=l[f];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Ll=new E(Ae),Vx="ETHERS_JS_SHARED",Ms=class extends Ct{static getApiKey(e){return e&&typeof e!="string"&&Ll.throwArgumentError("invalid apiKey","apiKey",e),e||Vx}static getUrl(e,t){Ll.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Ll.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var gc=new E(Ae),Tc="62e1ad51b37b8e00394bda3b",Is=class extends Ct{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=Tc:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:gc.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:gc.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===Tc}};var vc=new E(Ae),jx=1;function wc(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:jx++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:mt(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let f=new Error(p.error.message);return f.code=p.error.code,f.data=p.error.data,o(f)}s(p.result)})})}}function Hx(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:mt(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var Cs=class extends Yt{constructor(e,t){e==null&&vc.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Hx(e)):e.sendAsync?i=wc(e,e.sendAsync.bind(e)):e.send?i=wc(e,e.send.bind(e)):vc.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var _c=new E(Ae);function ru(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new Yt(a);case"ws":case"wss":return new va(a);default:_c.throwArgumentError("unsupported URL scheme","network",a)}}let t=ds(a);return(!t||!t._defaultProvider)&&_c.throwError("unsupported getDefaultProvider network",E.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:ks,AlchemyProvider:Ar,AnkrProvider:Ts,CloudflareProvider:vs,EtherscanProvider:ws,InfuraProvider:Mr,JsonRpcProvider:Yt,NodesmithProvider:Ms,PocketProvider:Is,Web3Provider:Cs,IpcProvider:null},e)}var te={};Gi(te,{AbiCoder:()=>Zi,ConstructorFragment:()=>Dt,ErrorFragment:()=>tn,EventFragment:()=>Ht,FormatTypes:()=>Te,Fragment:()=>qt,FunctionFragment:()=>Ot,HDNode:()=>It,Indexed:()=>da,Interface:()=>Ra,LogDescription:()=>ar,Logger:()=>E,ParamType:()=>yt,RLP:()=>to,SigningKey:()=>mn,SupportedAlgorithm:()=>Xn,TransactionDescription:()=>ir,TransactionTypes:()=>Ro,UnicodeNormalizationForm:()=>Gt,Utf8ErrorFuncs:()=>mo,Utf8ErrorReason:()=>Bt,_TypedDataEncoder:()=>gt,_fetchData:()=>Al,_toEscapedUtf8String:()=>Sd,accessListify:()=>sn,arrayify:()=>j,base58:()=>ca,base64:()=>Bd,checkProperties:()=>Ki,checkResultErrors:()=>$i,commify:()=>Rc,computeAddress:()=>hn,computeHmac:()=>ma,computePublicKey:()=>ts,concat:()=>ye,deepCopy:()=>mt,defaultAbiCoder:()=>Qr,defaultPath:()=>ha,defineReadOnly:()=>B,dnsEncode:()=>Yr,entropyToMnemonic:()=>bi,fetchJson:()=>Rn,formatBytes32String:()=>Rd,formatEther:()=>Pc,formatUnits:()=>Ul,getAccountPath:()=>_f,getAddress:()=>ce,getContractAddress:()=>di,getCreate2Address:()=>By,getIcapAddress:()=>Oy,getJsonWalletAddress:()=>Tl,getStatic:()=>ht,hashMessage:()=>nr,hexConcat:()=>kt,hexDataLength:()=>Nt,hexDataSlice:()=>Ie,hexStripZeros:()=>gd,hexValue:()=>Un,hexZeroPad:()=>he,hexlify:()=>W,id:()=>nn,isAddress:()=>Dy,isBytes:()=>un,isBytesLike:()=>ra,isHexString:()=>ie,isValidMnemonic:()=>wf,isValidName:()=>Ld,joinSignature:()=>Vr,keccak256:()=>fe,mnemonicToEntropy:()=>xr,mnemonicToSeed:()=>fl,namehash:()=>Sa,nameprep:()=>Od,parseBytes32String:()=>Pd,parseEther:()=>Nc,parseTransaction:()=>Po,parseUnits:()=>Vl,poll:()=>Pn,randomBytes:()=>Yn,recoverAddress:()=>fi,recoverPublicKey:()=>So,resolveProperties:()=>Ce,ripemd160:()=>is,serializeTransaction:()=>ns,sha256:()=>Xt,sha512:()=>dl,shallowCopy:()=>_e,shuffled:()=>os,solidityKeccak256:()=>Ec,solidityPack:()=>su,soliditySha256:()=>Mc,splitSignature:()=>Vn,stripZeros:()=>Zt,toUtf8Bytes:()=>we,toUtf8CodePoints:()=>Ca,toUtf8String:()=>Jt,verifyMessage:()=>Vf,verifyTypedData:()=>jf,zeroPad:()=>ri});var kc="solidity/5.7.0";var qx=new RegExp("^bytes([0-9]+)$"),Gx=new RegExp("^(u?int)([0-9]*)$"),zx=new RegExp("^(.*)\\[([0-9]*)\\]$"),Wx="0000000000000000000000000000000000000000000000000000000000000000",Ir=new E(kc);function Ac(a,e,t){switch(a){case"address":return t?ri(e,32):j(e);case"string":return we(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?ri(e,32):j(e)}let n=a.match(Gx);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Ir.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),ri(e,i/8)}if(n=a.match(qx),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Ir.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Ir.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+Wx).substring(0,66)):e}if(n=a.match(zx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Ir.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(Ac(i,o,!0))}),ye(s)}return Ir.throwArgumentError("invalid type","type",a)}function su(a,e){a.length!=e.length&&Ir.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(Ac(n,e[i]))}),W(ye(t))}function Ec(a,e){return fe(su(a,e))}function Mc(a,e){return Xt(su(a,e))}var Ic="units/5.7.0";var Cc=new E(Ic),Sc=["wei","kwei","mwei","gwei","szabo","finney","ether"];function Rc(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&Cc.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Ul(a,e){if(typeof e=="string"){let t=Sc.indexOf(e);t!==-1&&(e=3*t)}return Wi(a,e??18)}function Vl(a,e){if(typeof a!="string"&&Cc.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=Sc.indexOf(e);t!==-1&&(e=3*t)}return ln(a,e??18)}function Pc(a){return Ul(a,18)}function Nc(a){return Vl(a,18)}var ou="ethers/5.7.2";var Dc=new E(ou);try{let a=window;a._ethers==null&&(a._ethers=jl)}catch{}var Nn;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(Nn||(Nn={}));var uu;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(uu||(uu={}));var Cr;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Cr||(Cr={}));var du;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(du||(du={}));var Hl;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Hl||(Hl={}));var Ss;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Ss||(Ss={}));var Rs;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Rs||(Rs={}));var ql;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(ql||(ql={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var zt;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(zt||(zt={}));var zl="0x12345678",Gl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(Gl||(Gl={}));var Ne;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(Ne||(Ne={}));var me;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(me||(me={}));var Wl=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],Ti=class{static createInterface(){return new te.Interface(Wl)}static connect(e,t){return new oe(e,Wl,t)}};be(Ti,"abi",Wl);var Kl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],vi=class{static createInterface(){return new te.Interface(Kl)}static connect(e,t){return new oe(e,Kl,t)}};be(vi,"abi",Kl);var Oc=(a,e)=>{throw new Error(`${e}: ${a}`)},Jl=a=>a!=null;var{keccak256:Jx,toUtf8Bytes:$x}=te,{MaxUint256:Qx}=xt;var Sr=a=>te.formatEther(a),lu=a=>te.parseEther(a),pu=a=>lu(a[0]),$l=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(Ne.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(Jl)},wi=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return Qx;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},La=a=>Jx($x(a));var Rr=async(a,e)=>(await vi.connect(a,e).version()).toNumber(),Ql=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(Jl);var{hexDataSlice:Xl}=te,{MaxUint256:Xx}=xt,Bc=a=>{let e=Xl(a,0,3),t=F.from(Xl(a,4,35)),n=F.from(Xl(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Fc=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),Xx,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await wi(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},Yx=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Fc(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?na(a,e,t,n[0],i):Yx(a,e,t,n,i):Fc(a,e,t,n,i);var{MaxUint256:Lc}=xt,{AddressZero:Zx}=xt;async function eb(a,e){let t;try{return t=await a.getCapabilityRoles(te.hexZeroPad(e,4)),yu(t)}catch{return[]}}async function Ps(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:f,childSkillIndex:x}=Bc(s),C=Ti.connect(r,n.signer||n.provider),_=await eb(C,p);if(_.includes(Ne.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Lc}else{let{skillId:U}=await e.getDomain(f),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Lc;else{let{children:M}=await a.getSkill(l),J=M.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,Zx);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:tb}=xt,aa=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||Nn.Gnosis;this.endpointUrl=n?.customEndpointUrl||Cr[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await aa.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await aa.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await aa.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let f=p+1,x=await this.colony.getDomain(f);return{domainId:f,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,f=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return f&&(p=f?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return aa.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${tb}/noProof`,s=await aa.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var _t=a=>Array.from(Array(a-1)).map(e=>e+1);var Uc=10,$k=_t(Uc),Vc={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},jc=Uc-1;var Hc=6,Yk=_t(Hc),qc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},Gc=Hc-1;var zc=7,tA=_t(zc),Wc={1:[],2:[],3:[],4:[],5:[],6:[]},Kc=zc-1;var Jc=7,iA=_t(Jc),$c={1:[],2:[],3:[],4:[],5:[],6:[]},Qc=Jc-1;var Xc=4,oA=_t(Xc),Yc={1:[],2:[],3:[]},Zc=Xc-1;var em=5,lA=_t(em),tm={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},nm=em-1;var am=2,fA=_t(am),im={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},rm=am-1;var sm=4,hA=_t(sm),om={1:[1,2,3],2:[1,2,3],3:[1,2,3]},um=sm-1;var dm=7,gA=_t(dm),lm={1:[],2:[],3:[],4:[],5:[],6:[]},pm=dm-1;var ym=11,wA=_t(ym),Yl={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Zl=ym-1;var fm=6,AA=_t(fm),cm={1:[],2:[],3:[],4:[],5:[]},mm=fm-1;var ia=(a,e,t)=>{switch(a){case me.CoinMachine:{let n=Vc[e];return!!n&&!n.includes(t)}case me.EvaluatedExpenditure:{let n=qc[e];return!!n&&!n.includes(t)}case me.FundingQueue:{let n=Wc[e];return!!n&&!n.includes(t)}case me.IVotingReputation:{let n=Yl[e];return!!n&&!n.includes(t)}case me.OneTxPayment:{let n=$c[e];return!!n&&!n.includes(t)}case me.ReputationBootstrapper:{let n=Yc[e];return!!n&&!n.includes(t)}case me.StagedExpenditure:{let n=im[e];return!!n&&!n.includes(t)}case me.StakedExpenditure:{let n=tm[e];return!!n&&!n.includes(t)}case me.StreamingPayments:{let n=om[e];return!!n&&!n.includes(t)}case me.TokenSupplier:{let n=lm[e];return!!n&&!n.includes(t)}case me.VotingReputation:{let n=Yl[e];return!!n&&!n.includes(t)}case me.Whitelist:{let n=cm[e];return!!n&&!n.includes(t)}default:return Oc(a,"Could not find extension with name")}};var fu={[me.CoinMachine]:jc,[me.EvaluatedExpenditure]:Gc,[me.FundingQueue]:Kc,[me.IVotingReputation]:Zl,[me.OneTxPayment]:Qc,[me.ReputationBootstrapper]:Zc,[me.StagedExpenditure]:rm,[me.StakedExpenditure]:nm,[me.StreamingPayments]:um,[me.TokenSupplier]:pm,[me.VotingReputation]:Zl,[me.Whitelist]:mm};var Fh=kn(hm(),1);var vp=kn(Dh(),1);var Re;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Re||(Re={}));var Tp=2,gp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(gp||(gp={}));var Oh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,c1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),wp=(a,e)=>{let t=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=vp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==Tp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Oh(t.errors);throw new Error(n)};var Bh=(a,e)=>{let t=a===Re.Colony?c1(e):e,n=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=vp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:Tp});if(!n.success){let i=Oh(n.errors);throw new Error(i)}return n.data};var _p=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},kp=_p;var Ap=(0,Fh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Vs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Br=class{adapter;constructor(e){this.adapter=e||new kp}static eventSupportsMetadata(e){return!!Object.keys(Vs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await Ap(n)).json();return wp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await Ap(n)).json(),s=Object.entries(Vs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return wp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await Ap(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Bh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var YE=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var Ep=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],vn=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};be(vn,"abi",Ep);var Mp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],wn=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};be(wn,"abi",Mp);var Ip=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};be(Ii,"abi",Ip);var Ku=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Lh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",F1=a=>a.length>1,Dn=class extends mi{constructor(...e){F1(e)?super(...e):super(Ku,Lh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Ku)}static connect(e,t){return new oe(e,Ku,t)}};be(Dn,"bytecode",Lh),be(Dn,"abi",Ku);var Cp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ci=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};be(Ci,"abi",Cp);var Sp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Si=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};be(Si,"abi",Sp);var Ri;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Ri||(Ri={}));var _n;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(_n||(_n={}));var{AddressZero:Uh}=xt;async function V1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var j1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await V1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Uh)}catch{i=!1}try{await t.nonces(Uh)}catch{r=!1}return n?i?t.tokenClientType=_n.Colony:(t=Ci.connect(a,e),t.tokenClientType=_n.ColonyLegacy):r?(t=wn.connect(a,e),t.tokenClientType=_n.Erc2612):(t=vn.connect(a,e),t.tokenClientType=_n.Erc20),t.clientType=Ri.TokenClient,t},Rp=j1;var H1=(a,e)=>{let t=Si.connect(a,e);return t.clientType=Ri.TokenLockingClient,t},Pp=H1;var{AddressZero:Np}=xt,q1=vn.connect(Np,new ta.BaseProvider(3656691)).interface,G1=Ii.connect(Np,new ta.BaseProvider(3656691)).interface,z1=wn.connect(Np,new ta.BaseProvider(3656691)).interface;var Dp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],js=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};js.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Hs=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Hs.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Pi=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Pi.abi=Bp;var wa=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Vs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Ql(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:K1,solidityKeccak256:J1,splitSignature:$1}=te,Ni=class extends wa{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=J1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=K1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=$1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Fp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Di.abi=Fp;var Lp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};Oi.abi=Lp;var Up=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Bi.abi=Up;var Vp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};Fi.abi=Vp;var jp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};Li.abi=jp;var Hp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};Ui.abi=Hp;var{AddressZero:ng}=xt,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(La(On.extensionType),e.address);if(t===ng)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!ia(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Ne.Administration,Ne.Funding],this.oneTxPaymentContract.address),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Ne.Administration,Ne.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[La(me.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},ja=On;ja.supportedVersions=[{version:3,factory:Fi},{version:4,factory:Li},{version:5,factory:Ui}],ja.extensionType=me.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=vn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var qs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var Gs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=wn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Vh=async(a,e)=>{let t=await Rp(e,a.signerOrProvider);switch(t.tokenClientType){case _n.Colony:return new qs(a,t);case _n.Erc20:return new Bn(a,t);case _n.Erc2612:return new Gs(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var qp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};Vi.abi=qp;var Gp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Gp)}static connect(e,t){return new oe(e,Gp,t)}};ji.abi=Gp;var zp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(zp)}static connect(e,t){return new oe(e,zp,t)}};Hi.abi=zp;var{AddressZero:Wp}=xt;var $u=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(La(Fn.extensionType),e.address);if(t===Wp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!ia(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Ps(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Wp,zl);return[e,t,Wp,zl,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Sr(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,Ne.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await wi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[La(me.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ha=Fn;Ha.supportedVersions=[{version:7,factory:Vi},{version:8,factory:ji},{version:9,factory:Hi}],Ha.extensionType=me.VotingReputation;var sg={["motion"]:Ha,["oneTx"]:ja},Lr=class{static async connect(e,t){let n=await Rr(t,e.signerOrProvider),i=Lr.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Vh(e,s),l=new Lr(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Lr.supportedVersions[Lr.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new aa(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ha.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:Ne.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:Ne.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:Ne.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:Ne.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await na(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,Ne.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await wi(x,this.colony,r,s),_=await wi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=sg[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!ia(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[La(i),t.getLatestSupportedVersion()],async s=>({...Ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return yu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=$l(r);return[e,n,s]},{roles:Ne.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=$l(r);return[e,n,s]},{roles:Ne.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:Ne.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Ur=Lr;Ur.supportedVersions=[{version:11,factory:Di},{version:12,factory:Oi},{version:13,factory:Bi}];var{splitSignature:og}=te,Qu=class extends wa{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=og(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var zs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Pp(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:jh}=te,{AddressZero:Kp}=xt,Ws=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Br(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||du[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Cr[this.network]},this.networkContract=Pi.connect(t?.customNetworkAddress||uu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new zs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new wa({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Ni({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new Qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Kp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Ur.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Ss[this.network],""):null}async getColonyAddress(e){let t=jh(`${e}${Ss[this.network]}`),n=await this.networkContract.addr(t);return n!==Kp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Rs[this.network],""):null}async getUserAddress(e){let t=jh(`${e}${Rs[this.network]}`),n=await this.networkContract.addr(t);return n!==Kp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var Hh=async a=>{if(!a.ext.oneTx){if(!ia(me.OneTxPayment,fu[me.OneTxPayment],a.version))throw new Error(`OneTxPayment extension of version ${fu[me.OneTxPayment]} is not compatible with the installed Colony version ${a.version}`);if(await a.installExtension("oneTx").tx().mined(),await a.updateExtensions(),!a.ext.oneTx)throw new Error("OneTxPayment extension could not be installed");let e=a.ext.oneTx;await a.setRoles(e.address,[Ne.Administration,Ne.Funding]).tx().mined()}};var{isAddress:dg}=te,Xu=new ta.JsonRpcProvider("http://127.0.0.1:8545"),qi,Ks,lg=()=>new on("0x0355596cdb5e5242ad082c4fe3f8bbe48c9dba843fe1f99dd8272f487e70efae",Xu),pg=async a=>{let e=lg(),n=await new Ws(e,{customNetworkAddress:a,reputationOracleEndpoint:"http://localhost:3000"}).getMetaColony();return await Hh(n),n},yg=async a=>{await qi.mint(lu(a)).tx().mined(),await qi.claimFunds().tx().mined();let e=await qi.getBalance();return Sr(e)},fg=async a=>{if(!qi.ext.oneTx)throw new Error("OneTxPayment extension not installed");return qi.ext.oneTx.pay(a,pu`10`).tx()},cg=async()=>{await Xu.send("evm_increaseTime",[3600]),await Xu.send("evm_mine",[]),await Xu.send("evm_mine",[])},mg=async a=>(await qi.getReputation(a)).toString(),Yu=document.querySelector("#address"),qh=document.querySelector("#button_connect"),Jp=document.querySelector("#funding_amount"),Gh=document.querySelector("#button_fund"),zh=document.querySelector("#recipient"),Wh=document.querySelector("#button_pay"),Kh=document.querySelector("#button_jump"),Jh=document.querySelector("#button_get_reputation"),$p=document.querySelector("#error"),$h=document.querySelector("#result");if(!Yu||!Jp||!zh||!$p||!$h||!qh||!Gh||!Wh||!Kh||!Jh)throw new Error("Could not find all required HTML elements");var Zu=a=>{$p.innerText=`Found an error: ${a.message}`,console.error(a)},Qh=()=>{$p.innerText=""},Ln=a=>{$h.innerText=a};qh.addEventListener("click",async()=>{Qh();let a=Yu.value;if(!dg(a))return Zu(new Error("This is not a valid address"));Ln("Processing...");try{let e=await pg(Yu.value);qi=e,Ln(` +`)}`,c1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),wp=(a,e)=>{let t=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=vp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==Tp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Oh(t.errors);throw new Error(n)};var Bh=(a,e)=>{let t=a===Re.Colony?c1(e):e,n=(i=>{let r=p=>{let f=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?f(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=vp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:Tp});if(!n.success){let i=Oh(n.errors);throw new Error(i)}return n.data};var _p=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},kp=_p;var Ap=(0,Fh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Vs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Br=class{adapter;constructor(e){this.adapter=e||new kp}static eventSupportsMetadata(e){return!!Object.keys(Vs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await Ap(n)).json();return wp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await Ap(n)).json(),s=Object.entries(Vs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return wp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await Ap(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Bh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var YE=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var Ep=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],vn=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};be(vn,"abi",Ep);var Mp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],wn=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};be(wn,"abi",Mp);var Ip=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};be(Ii,"abi",Ip);var Ku=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Lh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",F1=a=>a.length>1,Dn=class extends mi{constructor(...e){F1(e)?super(...e):super(Ku,Lh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Ku)}static connect(e,t){return new oe(e,Ku,t)}};be(Dn,"bytecode",Lh),be(Dn,"abi",Ku);var Cp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ci=class{static createInterface(){return new te.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};be(Ci,"abi",Cp);var Sp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Si=class{static createInterface(){return new te.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};be(Si,"abi",Sp);var Ri;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Ri||(Ri={}));var _n;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(_n||(_n={}));var{AddressZero:Uh}=xt;async function V1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var j1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await V1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Uh)}catch{i=!1}try{await t.nonces(Uh)}catch{r=!1}return n?i?t.tokenClientType=_n.Colony:(t=Ci.connect(a,e),t.tokenClientType=_n.ColonyLegacy):r?(t=wn.connect(a,e),t.tokenClientType=_n.Erc2612):(t=vn.connect(a,e),t.tokenClientType=_n.Erc20),t.clientType=Ri.TokenClient,t},Rp=j1;var H1=(a,e)=>{let t=Si.connect(a,e);return t.clientType=Ri.TokenLockingClient,t},Pp=H1;var{AddressZero:Np}=xt,q1=vn.connect(Np,new ta.BaseProvider(3656691)).interface,G1=Ii.connect(Np,new ta.BaseProvider(3656691)).interface,z1=wn.connect(Np,new ta.BaseProvider(3656691)).interface;var Dp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],js=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};js.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Hs=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Hs.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Pi=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Pi.abi=Bp;var wa=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Vs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Ql(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:K1,solidityKeccak256:J1,splitSignature:$1}=te,Ni=class extends wa{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=J1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=K1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=$1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Fp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Di.abi=Fp;var Lp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};Oi.abi=Lp;var Up=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Bi.abi=Up;var Vp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};Fi.abi=Vp;var jp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};Li.abi=jp;var Hp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};Ui.abi=Hp;var{AddressZero:ng}=xt,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(La(On.extensionType),e.address);if(t===ng)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!ia(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Ne.Administration,Ne.Funding],this.oneTxPaymentContract.address),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[Ne.Administration,Ne.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[La(me.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},ja=On;ja.supportedVersions=[{version:3,factory:Fi},{version:4,factory:Li},{version:5,factory:Ui}],ja.extensionType=me.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=vn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var qs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var Gs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=wn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Vh=async(a,e)=>{let t=await Rp(e,a.signerOrProvider);switch(t.tokenClientType){case _n.Colony:return new qs(a,t);case _n.Erc20:return new Bn(a,t);case _n.Erc2612:return new Gs(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var qp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};Vi.abi=qp;var Gp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Gp)}static connect(e,t){return new oe(e,Gp,t)}};ji.abi=Gp;var zp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(zp)}static connect(e,t){return new oe(e,zp,t)}};Hi.abi=zp;var{AddressZero:Wp}=xt;var $u=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(La(Fn.extensionType),e.address);if(t===Wp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Rr(t,e.colonyNetwork.signerOrProvider);if(!ia(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Ps(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Wp,zl);return[e,t,Wp,zl,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Sr(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await na(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,Ne.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await wi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[La(me.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Ha=Fn;Ha.supportedVersions=[{version:7,factory:Vi},{version:8,factory:ji},{version:9,factory:Hi}],Ha.extensionType=me.VotingReputation;var sg={["motion"]:Ha,["oneTx"]:ja},Lr=class{static async connect(e,t){let n=await Rr(t,e.signerOrProvider),i=Lr.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Vh(e,s),l=new Lr(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Lr.supportedVersions[Lr.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new aa(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Fr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Ha.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:Ne.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:Ne.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:Ne.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:Ne.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await na(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,Ne.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await wi(x,this.colony,r,s),_=await wi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=sg[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!ia(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[La(i),t.getLatestSupportedVersion()],async s=>({...Ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return yu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=$l(r);return[e,n,s]},{roles:Ne.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=$l(r);return[e,n,s]},{roles:Ne.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:Ne.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},Ur=Lr;Ur.supportedVersions=[{version:11,factory:Di},{version:12,factory:Oi},{version:13,factory:Bi}];var{splitSignature:og}=te,Qu=class extends wa{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=og(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var zs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Pp(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:jh}=te,{AddressZero:Kp}=xt,Ws=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Br(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||du[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Cr[this.network]},this.networkContract=Pi.connect(t?.customNetworkAddress||uu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new zs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new wa({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Ni({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new Qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Kp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return Ur.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Ss[this.network],""):null}async getColonyAddress(e){let t=jh(`${e}${Ss[this.network]}`),n=await this.networkContract.addr(t);return n!==Kp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Rs[this.network],""):null}async getUserAddress(e){let t=jh(`${e}${Rs[this.network]}`),n=await this.networkContract.addr(t);return n!==Kp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var Hh=async a=>{if(!a.ext.oneTx){if(!ia(me.OneTxPayment,fu[me.OneTxPayment],a.version))throw new Error(`OneTxPayment extension of version ${fu[me.OneTxPayment]} is not compatible with the installed Colony version ${a.version}`);if(await a.installExtension("oneTx").tx().mined(),await a.updateExtensions(),!a.ext.oneTx)throw new Error("OneTxPayment extension could not be installed");let e=a.ext.oneTx;await a.setRoles(e.address,[Ne.Administration,Ne.Funding]).tx().mined()}};var{isAddress:dg}=te,Xu=new ta.JsonRpcProvider("http://127.0.0.1:8545"),qi,Ks,lg=()=>new on("0x0355596cdb5e5242ad082c4fe3f8bbe48c9dba843fe1f99dd8272f487e70efae",Xu),pg=async a=>{let e=lg(),n=await new Ws(e,{customNetworkAddress:a,reputationOracleEndpoint:"http://localhost:3000"}).getMetaColony();return await Hh(n),n},yg=async a=>{await qi.mint(lu(a)).tx().mined(),await qi.claimFunds().tx().mined();let e=await qi.getBalance();return Sr(e)},fg=async a=>{if(!qi.ext.oneTx)throw new Error("OneTxPayment extension not installed");return qi.ext.oneTx.pay(a,pu`10`).tx()},cg=async()=>{await Xu.send("evm_increaseTime",[3600]),await Xu.send("evm_mine",[]),await Xu.send("evm_mine",[])},mg=async a=>(await qi.getReputation(a)).toString(),Yu=document.querySelector("#address"),qh=document.querySelector("#button_connect"),Jp=document.querySelector("#funding_amount"),Gh=document.querySelector("#button_fund"),zh=document.querySelector("#recipient"),Wh=document.querySelector("#button_pay"),Kh=document.querySelector("#button_jump"),Jh=document.querySelector("#button_get_reputation"),$p=document.querySelector("#error"),$h=document.querySelector("#result");if(!Yu||!Jp||!zh||!$p||!$h||!qh||!Gh||!Wh||!Kh||!Jh)throw new Error("Could not find all required HTML elements");var Zu=a=>{$p.innerText=`Found an error: ${a.message}`,console.error(a)},Qh=()=>{$p.innerText=""},Ln=a=>{$h.innerText=a};qh.addEventListener("click",async()=>{Qh();let a=Yu.value;if(!dg(a))return Zu(new Error("This is not a valid address"));Ln("Processing...");try{let e=await pg(Yu.value);qi=e,Ln(` Connected to Colony with address: ${e.address}. Colony version: ${e.version}. `)}catch(e){Zu(e),Ln("")}finally{Yu.value=""}return null});Gh.addEventListener("click",async()=>{Qh(),Ln("Processing...");try{let a=Jp.value,e=await yg(a);Ln(`Funded MetaColony! Current funding: ${e} CLNY`)}catch(a){Zu(a),Ln("")}finally{Jp.value=""}return null});Wh.addEventListener("click",async()=>{Ks=zh.value,Ln("Processing...");try{await fg(Ks)}catch(a){Zu(a),Ln("")}Ln(`Successfully paid 10 CLNY to ${Ks}`)});Kh.addEventListener("click",async()=>{await cg(),Ln("Whooo that was a hell of a ride. Welcome to the future")});Jh.addEventListener("click",async()=>{let a=await mg(Ks);Ln(`User ${Ks} has ${Sr(a)} reputation points`)});})(); diff --git a/metamask.js b/metamask.js index 6b8587ff7..6d1376b0b 100644 --- a/metamask.js +++ b/metamask.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),O5)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var B5="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ns=null;function df(a){if(ns==null&&(ns=B5.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),hn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ns=null,new Error("BIP39 Wordlist for en (English) FAILED")}var el=class extends hn{constructor(){super("en")}getWord(e){return df(this),ns[e]}getWordIndex(e){return df(this),ns.indexOf(e)}},tl=new el;hn.register(tl);var hi={en:tl};var lf="hdnode/5.7.0";var as=new M(lf),F5=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),L5=ve("Bitcoin seed"),cr=2147483648;function yf(a){return(1<=256)throw new Error("Depth too large!");return pf(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,me(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new It(fr,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~cr));let n=new Uint8Array(37);if(e&cr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(fa(Qn.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=Do(F.from(r).add(this.privateKey).mod(F5)):l=new cn(W(r))._addPoint(this.publicKey);let p=t,f=this.mnemonic;return f&&(p=Object.freeze({phrase:f.phrase,path:t,locale:f.locale||"en"})),new It(fr,o,l,this.fingerprint,Do(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=cr)throw new Error("invalid path index - "+r);n=n._derive(cr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=cr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(fa(Qn.sha512,L5,n));return new It(fr,Do(i.slice(0,32)),null,"0x00000000",Do(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=nl(n),e=xi(mr(e,n),n),It._fromSeed(al(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return It._fromSeed(e,null)}static fromExtendedKey(e){let t=ya.decode(e);(t.length!==82||pf(t.slice(0,78))!==e)&&as.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new It(fr,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new It(fr,W(o.slice(1)),null,i,s,r,n,null)}return as.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function al(a,e){e||(e="");let t=ve("mnemonic"+e,Gt.NFKD);return mi(ve(a,Gt.NFKD),t,2048,64,"sha512")}function mr(a,e){e=nl(e),as.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=yf(s);if((j(Xt(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function xi(a,e){if(e=nl(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&U5(8-n)),n+=3);let i=a.length/4,r=j(Xt(a))[0]&yf(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function ff(a,e){try{return mr(a,e),!0}catch{}return!1}function cf(a){return(typeof a!="number"||a<0||a>=cr||a%1)&&as.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var mf="random/5.7.0";var il=new M(mf);function V5(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var hf=V5(),Oo=hf.crypto||hf.msCrypto;(!Oo||!Oo.getRandomValues)&&(il.warn("WARNING: Missing strong random number source"),Oo={getRandomValues:function(a){return il.throwError("no secure random source avaialble",M.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function Xn(a){(a<=0||a>1024||a%1||a!=a)&&il.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Oo.getRandomValues(e),j(e)}function is(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var ol=_n(sl());var Bo="json-wallets/5.7.0";function ma(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function hr(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),E=new ha.default.Counter(x),J=new ha.default.ModeOfOperation.ctr(O,E),$=j(J.encrypt(i)),de=fe(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:bf(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(f).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=Xn(16),N=new ha.default.Counter(R),q=new ha.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+hr(I.getUTCMonth()+1,2)+"-"+hr(I.getUTCDate(),2)+"T"+hr(I.getUTCHours(),2)+"-"+hr(I.getUTCMinutes(),2)+"-"+hr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function Ef(a,e,t){if(Fo(a)){t&&t(0);let n=dl(a,e);return t&&t(1),Promise.resolve(n)}return Lo(a)?Mf(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function If(a,e){if(Fo(a))return dl(a,e);if(Lo(a))return Af(a,e);throw new Error("invalid JSON wallet")}var Cf="wallet/5.7.0";var Sf=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},xr=new M(Cf);function z5(a){return a!=null&&ie(a.privateKey,32)&&a.address!=null}function W5(a){let e=a.mnemonic;return e&&e.phrase}var Cn=class extends St{constructor(e,t){if(super(),z5(e)){let n=new cn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",mn(this.publicKey)),this.address!==ce(e.address)&&xr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),W5(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||ca,locale:i.locale||"en"}));let r=this.mnemonic,s=It.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);mn(s.privateKey)!==this.address&&xr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(cn.isSigningKey(e))e.curve!=="secp256k1"&&xr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new cn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",mn(this.publicKey))}t&&!$t.isProvider(t)&&xr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Cn(this,e)}signTransaction(e){return Ce(e).then(t=>{t.from!=null&&(ce(t.from)!==this.address&&xr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(fe(Zr(t)));return Zr(t,n)})}signMessage(e){return Sf(this,void 0,void 0,function*(){return Fr(this._signingKey().signDigest(er(e)))})}_signTypedData(e,t,n){return Sf(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,r=>(this.provider==null&&xr.throwError("cannot resolve ENS names without a provider",M.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return Fr(this._signingKey().signDigest(bt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),cl(this,e,t,n)}static createRandom(e){let t=Xn(16);e||(e={}),e.extraEntropy&&(t=j(Ie(fe(ye([t,e.extraEntropy])),0,16)));let n=xi(t,e.locale);return Cn.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return Ef(e,t,n).then(i=>new Cn(i))}static fromEncryptedJsonSync(e,t){return new Cn(If(e,t))}static fromMnemonic(e,t,n){return t||(t=ca),new Cn(It.fromMnemonic(e,null,n).derivePath(t))}};function Rf(a,e){return yi(er(a),e)}function Pf(a,e,t,n){return yi(bt.hash(a,e,t),n)}var ea={};Hi(ea,{AlchemyProvider:()=>_r,AlchemyWebSocketProvider:()=>hs,AnkrProvider:()=>xs,BaseProvider:()=>Zn,CloudflareProvider:()=>bs,EtherscanProvider:()=>gs,FallbackProvider:()=>vs,Formatter:()=>Y,InfuraProvider:()=>Ar,InfuraWebSocketProvider:()=>_s,IpcProvider:()=>El,JsonRpcBatchProvider:()=>eu,JsonRpcProvider:()=>Yt,JsonRpcSigner:()=>vr,NodesmithProvider:()=>ks,PocketProvider:()=>As,Provider:()=>$t,Resolver:()=>Tr,StaticJsonRpcProvider:()=>ms,UrlJsonRpcProvider:()=>Ct,Web3Provider:()=>Ms,WebSocketProvider:()=>ga,getDefaultProvider:()=>tu,getNetwork:()=>ss,isCommunityResourcable:()=>xl,isCommunityResource:()=>ds,showThrottleMessage:()=>Yn});var Nf="networks/5.7.1";var Df=new M(Nf);function K5(a){return a&&typeof a.renetwork=="function"}function xa(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return xa(t)},e}function jo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return jo(a,n)},t}var Of={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:xa("homestead")},Bf={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:xa("ropsten")},Ff={chainId:63,name:"classicMordor",_defaultProvider:jo("https://www.ethercluster.com/mordor","classicMordor")},Vo={unspecified:{chainId:0,name:"unspecified"},homestead:Of,mainnet:Of,morden:{chainId:2,name:"morden"},ropsten:Bf,testnet:Bf,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:xa("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:xa("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:xa("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:xa("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:jo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Ff,classicTestnet:Ff,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:jo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:xa("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:xa("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function ss(a){if(a==null)return null;if(typeof a=="number"){for(let n in Vo){let i=Vo[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=Vo[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=Vo[a.name];if(!e)return typeof a.chainId!="number"&&Df.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&Df.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(K5(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Lf="web/5.7.1";var J5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Uf(a,e){return J5(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var $5=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Sn=new M(Lf);function Vf(a){return new Promise(e=>{setTimeout(e,a)})}function Da(a,e){if(a==null)return null;if(typeof a=="string")return a;if(aa(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Jt(a)}catch{}return W(a)}return a}function Q5(a){return ve(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function ml(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Sn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Sn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},f=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Sn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(f=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Sn.throwError("basic authentication requires a secure https url",M.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+Zi(ve(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?Yi(_[3]):Q5(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Sn.throwError("processing response error",M.errors.SERVER_ERROR,{body:Da(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(E,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Sn.makeError("timeout",M.errors.TIMEOUT,{requestBody:Da(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return $5(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Sn.throwError("bad response",M.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Da(H,U.headers?U.headers["content-type"]:null),requestBody:Da(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let E=yield t(H,U);return S.cancel(),E}catch(E){if(E.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Jt(r))}catch(l){Sn.throwError("invalid JSON",M.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=ve(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return ml(a,i,n)}function Pn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(f){if(f!==void 0)s()&&t(f);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(f){s()&&n(f)})}p()})}var vl=_n(Gf());var Ae="providers/5.7.2";var us=new M(Ae),Y=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),f=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:Y.allowNull(this.accessList.bind(this),null),blockHash:Y.allowNull(s,null),blockNumber:Y.allowNull(l,null),transactionIndex:Y.allowNull(l,null),confirmations:Y.allowNull(l,null),from:t,gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),gasLimit:n,to:Y.allowNull(t,null),value:n,nonce:l,data:r,r:Y.allowNull(this.uint256),s:Y.allowNull(this.uint256),v:Y.allowNull(l),creates:Y.allowNull(t,null),raw:Y.allowNull(r)},e.transactionRequest={from:Y.allowNull(t),nonce:Y.allowNull(l),gasLimit:Y.allowNull(n),gasPrice:Y.allowNull(n),maxPriorityFeePerGas:Y.allowNull(n),maxFeePerGas:Y.allowNull(n),to:Y.allowNull(t),value:Y.allowNull(n),data:Y.allowNull(f),type:Y.allowNull(l),accessList:Y.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:Y.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:Y.allowNull(this.address,null),from:Y.allowNull(this.address,null),contractAddress:Y.allowNull(t,null),transactionIndex:l,root:Y.allowNull(o),gasUsed:n,logsBloom:Y.allowNull(r),blockHash:s,transactionHash:s,logs:Y.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:Y.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:Y.allowNull(n),status:Y.allowNull(l),type:p},e.block={hash:Y.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:Y.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:Y.allowNull(t),extraData:r,transactions:Y.allowNull(Y.arrayOf(s)),baseFeePerGas:Y.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=Y.allowNull(Y.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:Y.allowNull(i,void 0),toBlock:Y.allowNull(i,void 0),blockHash:Y.allowNull(s,void 0),address:Y.allowNull(t,void 0),topics:Y.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:Y.allowNull(l),blockHash:Y.allowNull(s),transactionIndex:l,removed:Y.allowNull(this.boolean.bind(this)),address:t,data:Y.allowFalsish(r,"0x"),topics:Y.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return sn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():us.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return ce(e)}callAddress(e){if(!ie(e,32))return null;let t=ce(Ie(e,12));return t===ro?null:t}contractAddress(e){return ui(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return Ln(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Nt(n)!==32?us.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return me(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=Y.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return Y.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=Y.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ie(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ie(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return Io(e)}receiptLog(e){return Y.check(this.formats.receiptLog,e)}receipt(e){let t=Y.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&us.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):us.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&us.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return Y.check(this.formats.filter,e)}filterLog(e){return Y.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function xl(a){return a&&typeof a.isCommunityResource=="function"}function ds(a){return xl(a)&&a.isCommunityResource()}var zf=!1;function Yn(){zf||(zf=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},he=new M(Ae),ix=10;function Wf(a){return a==null?"null":(Nt(a)!==32&&he.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function Kf(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[Wf(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return Wf(e)}).join("&")}function rx(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function gr(a){if(typeof a=="string"){if(a=a.toLowerCase(),Nt(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+Kf(a);if(xo.isForkEvent(a))throw he.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+Kf(a.topics||[])}throw new Error("invalid event - "+a)}function ls(){return new Date().getTime()}function Jf(a){return new Promise(e=>{setTimeout(e,a)})}var sx=["block","network","pending","poll"],wl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=rx(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||sx.indexOf(this.tag)>=0}},ox={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function bl(a){return me(F.from(a).toHexString(),32)}function $f(a){return ya.encode(ye([a,Ie(Xt(Xt(a)),0,4)]))}var Yf=new RegExp("^(ipfs)://(.*)$","i"),Qf=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Yf,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function zo(a,e){try{return Jt(ps(a,e))}catch{}return null}function ps(a,e){if(a==="0x")return null;let t=F.from(Ie(a,e,e+32)).toNumber(),n=F.from(Ie(a,t,t+32)).toNumber();return Ie(a,t+32,t+32+n)}function gl(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):he.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function Xf(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function ux(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function Zf(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===M.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:kt([e,Ia(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=kt(["0x9061b923",Zf([$r(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&he.throwError("resolver threw error",M.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=ps(r,0)),r}catch(r){if(r.code===M.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?ps(n,0):null})}_getAddress(e,t){let n=ox[String(e)];if(n==null&&he.throwError(`unsupported coin type: ${e}`,M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return $f(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return $f(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=vl.default.toWords(i.slice(2));return o.unshift(s),vl.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===Qi?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===M.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",bl(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&he.throwError("invalid or unsupported coin data",M.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return he.throwError("invalid or unsupported content hash data",M.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=ve(e);t=ye([bl(64),bl(t.length),t]),t.length%32!==0&&(t=ye([t,me("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Jt(n)})}},Tl=null,dx=1,Zn=class extends $t{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=mt(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):he.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||he.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Pn(()=>this._ready().then(e=>e,e=>{if(!(e.code===M.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return Tl==null&&(Tl=new Y),Tl}static getNetwork(e){return ss(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield Rn({url:p,errorPassThrough:!0},f,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return he.throwError(`response not found during CCIP fetch: ${C}`,M.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return he.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,M.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(ls()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=ls(),n=Ce({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=ls();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=dx++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)he.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",he.makeError("network block skew detected",M.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return he.throwError("provider does not support network detection",M.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield Jf(0),this._network;let n=he.makeError("underlying network changed",M.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=ls();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,f=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield Jf(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{f()||o(he.makeError("timeout exceeded",M.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Ce({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Ln(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return he.throwError("bad result from backend",M.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Nt(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&he.throwError("Transaction hash mismatch from Provider.sendTransaction.",M.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&he.throwError("transaction failed",M.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Ce(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Ce(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=ix&&he.throwError("CCIP read exceeded maximum redirections",M.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Nt(r)%32===4)try{let s=Ie(r,4),o=Ie(s,0,32);F.from(o).eq(i)||he.throwError("CCIP Read sender did not match",M.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ie(s,32,64)).toNumber(),f=F.from(Ie(s,p,p+32)).toNumber(),x=Ie(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Pn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Ce({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),Y.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&he.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new Tr(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||he.throwError("network does not support ENS",M.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Ia(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ie(e))throw n}typeof e!="string"&&he.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=zo(yield this.call({to:n,data:"0x691f3431"+Ia(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new Tr(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o}try{let o=zo(yield this.call({to:s,data:"0x691f3431"+Ia(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==M.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return he.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new wl(gr(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=gr(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=gr(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=gr(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=gr(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=gr(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var ba=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Mt=new M(Ae),lx=["call","estimateGas"];function fs(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ie(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=fs(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return fs(JSON.parse(a),e)}catch{}return null}function tc(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=fs(e,!0);if(r)return r.data;Mt.throwError("missing revert data in call exception; Transaction reverted without a reason string",M.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=fs(e.body,!1);r==null&&(r=fs(e,!1)),r&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===M.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Mt.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Mt.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Mt.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Mt.throwError("legacy pre-eip-155 transactions not supported",M.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),lx.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function ec(a){return new Promise(function(e){setTimeout(e,a)})}function px(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function ys(a){return a&&a.toLowerCase()}var _l={},vr=class extends St{constructor(e,t,n){if(super(),e!==_l)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Mt.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Mt.throwError("cannot alter JSON-RPC Signer connection",M.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new kl(_l,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Mt.throwError("unknown account #"+this._index,M.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>ba(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Mt.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Ce({tx:Ce(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Mt.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected transaction",M.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),tc("sendTransaction",s,r)))})}signTransaction(e){return Mt.throwError("signing transactions is unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return ba(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Pn(()=>ba(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return ba(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return ba(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return ba(this,void 0,void 0,function*(){let i=yield bt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(bt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected signing",M.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return ba(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},kl=class extends vr{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},yx={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},Yt=class extends Zn{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=mt(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return ba(this,void 0,void 0,function*(){yield ec(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=mt(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Mt.throwError("could not detect network",M.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new vr(_l,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:ct(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=Rn(this.connection,JSON.stringify(n),px).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[ys(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[ys(t.address),t.blockTag]];case"getCode":return["eth_getCode",[ys(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[ys(t.address),me(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=mt(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=ys(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return ba(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Mt.throwError(e+" not implemented",M.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return tc(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return ec(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(yx);if(t)for(let r in t)t[r]&&(n[r]=!0);zi(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Ln(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=sn(e.accessList)),i}};var wr=null;try{if(wr=WebSocket,wr==null)throw new Error("inject please")}catch{let e=new M(Ae);wr=function(){e.throwError("WebSockets not supported in this environment",M.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var Al=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Wo=new M(Ae),fx=1,ga=class extends Yt{constructor(e,t){t==="any"&&Wo.throwError("WebSocketProvider does not support 'any' network yet",M.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new wr(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){Wo.throwError("cannot reset events block on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){Wo.throwError("cannot set polling interval on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return Al(this,void 0,void 0,function*(){return null})}set polling(e){!e||Wo.throwError("cannot set polling on WebSocketProvider",M.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=fx++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return Al(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return Al(this,void 0,void 0,function*(){this.websocket.readyState===wr.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var cx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},cs=new M(Ae),ms=class extends Yt{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return cx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||cs.throwError("no network detected",M.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},Ct=class extends ms{constructor(e,t){cs.checkAbstract(new.target,Ct),e=mt(new.target,"getNetwork")(e),t=mt(new.target,"getApiKey")(t);let n=mt(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){cs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return cs.throwError("API provider does not support signing",M.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return cs.throwError("not implemented; sub-classes must override getUrl",M.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var nc=new M(Ae),Ko="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",hs=class extends ga{constructor(e,t){let n=new _r(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===Ko}},_r=class extends Ct{static getWebSocketProvider(e,t){return new hs(e,t)}static getApiKey(e){return e==null?Ko:(e&&typeof e!="string"&&nc.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:nc.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===Ko&&Yn(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===Ko}};var mx=new M(Ae),Jo="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function hx(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return mx.throwArgumentError("unsupported network","name",a)}var xs=class extends Ct{isCommunityResource(){return this.apiKey===Jo}static getApiKey(e){return e??Jo}static getUrl(e,t){t==null&&(t=Jo);let n={allowGzip:!0,url:"https://"+hx(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===Jo&&Yn(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var xx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},ac=new M(Ae),bs=class extends Ct{static getApiKey(e){return e!=null&&ac.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:ac.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return xx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var $o=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Oa=new M(Ae);function ic(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Ln(W(n)):t==="accessList"?n="["+sn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function bx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function rc(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function sc(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function Ml(a,e,t){if(a==="call"&&e.code===M.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Oa.throwError("missing revert data in call exception",M.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===M.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Oa.throwError("insufficient funds for intrinsic transaction cost",M.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Oa.throwError("nonce has already been used",M.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Oa.throwError("replacement fee too low",M.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Oa.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",M.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var gs=class extends Zn{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Oa.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return $o(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?rc:bx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(f,x)=>(this.isCommunityResource()&&Yn(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(f=>`${f}=${r[f]}`).join("&"));let p=yield Rn(o,l,s||rc);return this.emit("debug",{action:"response",request:i,response:ct(p),provider:this}),p})}detectNetwork(){return $o(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return $o(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Ml("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=ic(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Ml("call",r,t.transaction)}}case"estimateGas":{let i=ic(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Ml("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=sc(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=sc(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Oa.throwError("unsupported topic count",M.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Oa.throwError("unsupported topic format",M.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var Yo=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(f){try{p(n.next(f))}catch(x){s(x)}}function l(f){try{p(n.throw(f))}catch(x){s(x)}}function p(f){f.done?r(f.value):i(f.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},bi=new M(Ae);function Qo(){return new Date().getTime()}function oc(a){let e=null;for(let t=0;te?null:(n+i)/2}function kr(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>kr(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=kr(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var gx=1;function dc(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var Tx=[M.errors.CALL_EXCEPTION,M.errors.INSUFFICIENT_FUNDS,M.errors.NONCE_EXPIRED,M.errors.REPLACEMENT_UNDERPRICED,M.errors.UNPREDICTABLE_GAS_LIMIT],vx=["address","args","errorArgs","errorSignature","method","transaction"];function Xo(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function wx(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function _x(a,e,t){let n=kr;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=uc(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return uc(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,kr(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),kr(i))}:n=function(i){return i==null?null:kr(i)};break;default:throw new Error("unknown method: "+e)}return wx(n,a.quorum)}function Ts(a,e){return Yo(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Pn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function kx(a,e,t,n){return Yo(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ie(n.blockTag)&&(i=yield Ts(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield Ts(a,e)),i.getLogs(r)}}return bi.throwError("unknown method error",M.errors.UNKNOWN_ERROR,{method:t,params:n})})}var vs=class extends Zn{constructor(e,t){e.length===0&&bi.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if($t.isProvider(s)){let f=ds(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:f,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=ds(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&bi.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&bi.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=oc(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return Yo(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return oc(e)})}perform(e,t){return Yo(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(f=>f.hash,f=>f)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=Qo(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=kx(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Xo(_,Qo()),request:{method:e,params:ct(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Xo(_,Qo()),request:{method:e,params:ct(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:Xo(_,null),request:{method:e,params:ct(t)},provider:this}),p+=_.weight}let f=[];i.forEach(_=>{_.done||!_.runner||(f.push(_.runner),_.staller&&f.push(_.staller.getPromise()))}),f.length&&(yield Promise.race(f));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield dc(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return Tx.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};vx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),bi.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),bi.throwError("failed to meet quorum",M.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>Xo(l)),provider:this})})}};var El=null;var Zo=new M(Ae),ws="84842078b09946638c03157f83405213",_s=class extends ga{constructor(e,t){let n=new Ar(e,t),i=n.connection;i.password&&Zo.throwError("INFURA WebSocket project secrets unsupported",M.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===ws}},Ar=class extends Ct{static getWebSocketProvider(e,t){return new _s(e,t)}static getApiKey(e){let t={apiKey:ws,projectId:ws,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(Zo.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),Zo.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:Zo.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===ws&&Yn(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===ws}};var eu=class extends Yt{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:ct(o),provider:this}),Rn(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,f)=>{let x=l[f];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Il=new M(Ae),Ax="ETHERS_JS_SHARED",ks=class extends Ct{static getApiKey(e){return e&&typeof e!="string"&&Il.throwArgumentError("invalid apiKey","apiKey",e),e||Ax}static getUrl(e,t){Il.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Il.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var lc=new M(Ae),pc="62e1ad51b37b8e00394bda3b",As=class extends Ct{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=pc:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:lc.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:lc.throwError("unsupported network",M.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===pc}};var yc=new M(Ae),Mx=1;function fc(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:Mx++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:ct(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let f=new Error(p.error.message);return f.code=p.error.code,f.data=p.error.data,o(f)}s(p.result)})})}}function Ex(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:ct(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var Ms=class extends Yt{constructor(e,t){e==null&&yc.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Ex(e)):e.sendAsync?i=fc(e,e.sendAsync.bind(e)):e.send?i=fc(e,e.send.bind(e)):yc.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var cc=new M(Ae);function tu(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new Yt(a);case"ws":case"wss":return new ga(a);default:cc.throwArgumentError("unsupported URL scheme","network",a)}}let t=ss(a);return(!t||!t._defaultProvider)&&cc.throwError("unsupported getDefaultProvider network",M.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:vs,AlchemyProvider:_r,AnkrProvider:xs,CloudflareProvider:bs,EtherscanProvider:gs,InfuraProvider:Ar,JsonRpcProvider:Yt,NodesmithProvider:ks,PocketProvider:As,Web3Provider:Ms,IpcProvider:null},e)}var ne={};Hi(ne,{AbiCoder:()=>Xi,ConstructorFragment:()=>Dt,ErrorFragment:()=>tn,EventFragment:()=>Ht,FormatTypes:()=>ge,Fragment:()=>qt,FunctionFragment:()=>Ot,HDNode:()=>It,Indexed:()=>oa,Interface:()=>Ca,LogDescription:()=>tr,Logger:()=>M,ParamType:()=>pt,RLP:()=>Xs,SigningKey:()=>cn,SupportedAlgorithm:()=>Qn,TransactionDescription:()=>nr,TransactionTypes:()=>Eo,UnicodeNormalizationForm:()=>Gt,Utf8ErrorFuncs:()=>po,Utf8ErrorReason:()=>Bt,_TypedDataEncoder:()=>bt,_fetchData:()=>ml,_toEscapedUtf8String:()=>Td,accessListify:()=>sn,arrayify:()=>j,base58:()=>ya,base64:()=>Md,checkProperties:()=>zi,checkResultErrors:()=>Ki,commify:()=>wc,computeAddress:()=>mn,computeHmac:()=>fa,computePublicKey:()=>Yr,concat:()=>ye,deepCopy:()=>ct,defaultAbiCoder:()=>Kr,defaultPath:()=>ca,defineReadOnly:()=>B,dnsEncode:()=>$r,entropyToMnemonic:()=>xi,fetchJson:()=>Rn,formatBytes32String:()=>vd,formatEther:()=>_c,formatUnits:()=>Cl,getAccountPath:()=>cf,getAddress:()=>ce,getContractAddress:()=>ui,getCreate2Address:()=>Ey,getIcapAddress:()=>My,getJsonWalletAddress:()=>ll,getStatic:()=>mt,hashMessage:()=>er,hexConcat:()=>kt,hexDataLength:()=>Nt,hexDataSlice:()=>Ie,hexStripZeros:()=>dd,hexValue:()=>Ln,hexZeroPad:()=>me,hexlify:()=>W,id:()=>nn,isAddress:()=>Ay,isBytes:()=>on,isBytesLike:()=>aa,isHexString:()=>ie,isValidMnemonic:()=>ff,isValidName:()=>Id,joinSignature:()=>Fr,keccak256:()=>fe,mnemonicToEntropy:()=>mr,mnemonicToSeed:()=>al,namehash:()=>Ia,nameprep:()=>Ad,parseBytes32String:()=>wd,parseEther:()=>kc,parseTransaction:()=>Io,parseUnits:()=>Sl,poll:()=>Pn,randomBytes:()=>Xn,recoverAddress:()=>yi,recoverPublicKey:()=>Mo,resolveProperties:()=>Ce,ripemd160:()=>ts,serializeTransaction:()=>Zr,sha256:()=>Xt,sha512:()=>Zd,shallowCopy:()=>_e,shuffled:()=>is,solidityKeccak256:()=>xc,solidityPack:()=>nu,soliditySha256:()=>bc,splitSignature:()=>Un,stripZeros:()=>Zt,toUtf8Bytes:()=>ve,toUtf8CodePoints:()=>Ea,toUtf8String:()=>Jt,verifyMessage:()=>Rf,verifyTypedData:()=>Pf,zeroPad:()=>ii});var mc="solidity/5.7.0";var Ix=new RegExp("^bytes([0-9]+)$"),Cx=new RegExp("^(u?int)([0-9]*)$"),Sx=new RegExp("^(.*)\\[([0-9]*)\\]$"),Rx="0000000000000000000000000000000000000000000000000000000000000000",Mr=new M(mc);function hc(a,e,t){switch(a){case"address":return t?ii(e,32):j(e);case"string":return ve(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?ii(e,32):j(e)}let n=a.match(Cx);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Mr.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),ii(e,i/8)}if(n=a.match(Ix),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Mr.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Mr.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+Rx).substring(0,66)):e}if(n=a.match(Sx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Mr.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(hc(i,o,!0))}),ye(s)}return Mr.throwArgumentError("invalid type","type",a)}function nu(a,e){a.length!=e.length&&Mr.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(hc(n,e[i]))}),W(ye(t))}function xc(a,e){return fe(nu(a,e))}function bc(a,e){return Xt(nu(a,e))}var gc="units/5.7.0";var Tc=new M(gc),vc=["wei","kwei","mwei","gwei","szabo","finney","ether"];function wc(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&Tc.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Cl(a,e){if(typeof e=="string"){let t=vc.indexOf(e);t!==-1&&(e=3*t)}return Gi(a,e??18)}function Sl(a,e){if(typeof a!="string"&&Tc.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=vc.indexOf(e);t!==-1&&(e=3*t)}return dn(a,e??18)}function _c(a){return Cl(a,18)}function kc(a){return Sl(a,18)}var au="ethers/5.7.2";var Ac=new M(au);try{let a=window;a._ethers==null&&(a._ethers=Rl)}catch{}var Nn;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(Nn||(Nn={}));var iu;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(iu||(iu={}));var Er;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Er||(Er={}));var ru;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(ru||(ru={}));var Pl;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Pl||(Pl={}));var Es;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Es||(Es={}));var Is;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Is||(Is={}));var Nl;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(Nl||(Nl={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var zt;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(zt||(zt={}));var Ol="0x12345678",Dl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(Dl||(Dl={}));var vt;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(vt||(vt={}));var we;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(we||(we={}));var Bl=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],gi=class{static createInterface(){return new ne.Interface(Bl)}static connect(e,t){return new oe(e,Bl,t)}};xe(gi,"abi",Bl);var Fl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],Ti=class{static createInterface(){return new ne.Interface(Fl)}static connect(e,t){return new oe(e,Fl,t)}};xe(Ti,"abi",Fl);var Mc=(a,e)=>{throw new Error(`${e}: ${a}`)},Ll=a=>a!=null;var{keccak256:Nx,toUtf8Bytes:Dx}=ne,{MaxUint256:Ox}=ht;var Ul=a=>ne.formatEther(a);var Vl=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(vt.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(Ll)},vi=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return Ox;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},Ba=a=>Nx(Dx(a));var Ir=async(a,e)=>(await Ti.connect(a,e).version()).toNumber(),jl=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(Ll);var{hexDataSlice:Hl}=ne,{MaxUint256:Bx}=ht,Ec=a=>{let e=Hl(a,0,3),t=F.from(Hl(a,4,35)),n=F.from(Hl(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Ic=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),Bx,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await vi(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},Fx=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Ic(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?ta(a,e,t,n[0],i):Fx(a,e,t,n,i):Ic(a,e,t,n,i);var{MaxUint256:Cc}=ht,{AddressZero:Lx}=ht;async function Ux(a,e){let t;try{return t=await a.getCapabilityRoles(ne.hexZeroPad(e,4)),su(t)}catch{return[]}}async function Cs(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:f,childSkillIndex:x}=Ec(s),C=gi.connect(r,n.signer||n.provider),_=await Ux(C,p);if(_.includes(vt.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Cc}else{let{skillId:U}=await e.getDomain(f),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Cc;else{let{children:E}=await a.getSkill(l),J=E.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,Lx);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:Vx}=ht,na=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||Nn.Gnosis;this.endpointUrl=n?.customEndpointUrl||Er[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await na.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await na.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await na.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let f=p+1,x=await this.colony.getDomain(f);return{domainId:f,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,f=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return f&&(p=f?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return na.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${Vx}/noProof`,s=await na.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var _t=a=>Array.from(Array(a-1)).map(e=>e+1);var Sc=10,Rk=_t(Sc),Rc={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},Pc=Sc-1;var Nc=6,Dk=_t(Nc),Dc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},Oc=Nc-1;var Bc=7,Fk=_t(Bc),Fc={1:[],2:[],3:[],4:[],5:[],6:[]},Lc=Bc-1;var Uc=7,Vk=_t(Uc),Vc={1:[],2:[],3:[],4:[],5:[],6:[]},jc=Uc-1;var Hc=4,qk=_t(Hc),qc={1:[],2:[],3:[]},Gc=Hc-1;var zc=5,Wk=_t(zc),Wc={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},Kc=zc-1;var Jc=2,$k=_t(Jc),$c={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},Qc=Jc-1;var Xc=4,Yk=_t(Xc),Yc={1:[1,2,3],2:[1,2,3],3:[1,2,3]},Zc=Xc-1;var em=7,tA=_t(em),tm={1:[],2:[],3:[],4:[],5:[],6:[]},nm=em-1;var am=11,iA=_t(am),ql={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Gl=am-1;var im=6,oA=_t(im),rm={1:[],2:[],3:[],4:[],5:[]},sm=im-1;var Fa=(a,e,t)=>{switch(a){case we.CoinMachine:{let n=Rc[e];return!!n&&!n.includes(t)}case we.EvaluatedExpenditure:{let n=Dc[e];return!!n&&!n.includes(t)}case we.FundingQueue:{let n=Fc[e];return!!n&&!n.includes(t)}case we.IVotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.OneTxPayment:{let n=Vc[e];return!!n&&!n.includes(t)}case we.ReputationBootstrapper:{let n=qc[e];return!!n&&!n.includes(t)}case we.StagedExpenditure:{let n=$c[e];return!!n&&!n.includes(t)}case we.StakedExpenditure:{let n=Wc[e];return!!n&&!n.includes(t)}case we.StreamingPayments:{let n=Yc[e];return!!n&&!n.includes(t)}case we.TokenSupplier:{let n=tm[e];return!!n&&!n.includes(t)}case we.VotingReputation:{let n=ql[e];return!!n&&!n.includes(t)}case we.Whitelist:{let n=rm[e];return!!n&&!n.includes(t)}default:return Mc(a,"Could not find extension with name")}};var jx={[we.CoinMachine]:Pc,[we.EvaluatedExpenditure]:Oc,[we.FundingQueue]:Lc,[we.IVotingReputation]:Gl,[we.OneTxPayment]:jc,[we.ReputationBootstrapper]:Gc,[we.StagedExpenditure]:Qc,[we.StakedExpenditure]:Kc,[we.StreamingPayments]:Zc,[we.TokenSupplier]:nm,[we.VotingReputation]:Gl,[we.Whitelist]:sm};var Ih=_n(om(),1);var yp=_n(Ah(),1);var Re;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Re||(Re={}));var pp=2,lp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(lp||(lp={}));var Mh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,e1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Mh(t.errors);throw new Error(n)};var Eh=(a,e)=>{let t=a===Re.Colony?e1(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:pp});if(!n.success){let i=Mh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ih.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Fs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Nr=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Fs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Fs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Eh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var DM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new ne.Interface(xp)}static connect(e,t){return new oe(e,xp,t)}};xe(Tn,"abi",xp);var bp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new ne.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(vn,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ei=class{static createInterface(){return new ne.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Ei,"abi",gp);var Vu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Ch="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",_1=a=>a.length>1,Dn=class extends ci{constructor(...e){_1(e)?super(...e):super(Vu,Ch,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new ne.Interface(Vu)}static connect(e,t){return new oe(e,Vu,t)}};xe(Dn,"bytecode",Ch),xe(Dn,"abi",Vu);var Tp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new ne.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(Ii,"abi",Tp);var vp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ci=class{static createInterface(){return new ne.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Si;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Si||(Si={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Sh}=ht;async function M1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var E1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await M1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Sh)}catch{i=!1}try{await t.nonces(Sh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Ii.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Si.TokenClient,t},wp=E1;var I1=(a,e)=>{let t=Ci.connect(a,e);return t.clientType=Si.TokenLockingClient,t},_p=I1;var{AddressZero:kp}=ht,C1=Tn.connect(kp,new ea.BaseProvider(3656691)).interface,S1=Ei.connect(kp,new ea.BaseProvider(3656691)).interface,R1=vn.connect(kp,new ea.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ls=class{static createInterface(){return new ne.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Ls.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Us=class{static createInterface(){return new ne.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};Us.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new ne.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Ri.abi=Ep;var Ta=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Fs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:N1,solidityKeccak256:D1,splitSignature:O1}=ne,Pi=class extends Ta{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=D1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=N1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=O1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var te=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new ne.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Ni.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new ne.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Di.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new ne.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Oi.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new ne.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Bi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new ne.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Fi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new ne.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Li.abi=Np;var{AddressZero:H1}=ht,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(On.extensionType),e.address);if(t===H1)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...te("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.OneTxPayment),t],async n=>({...te("ExtensionUpgraded",n)}))}},Va=On;Va.supportedVersions=[{version:3,factory:Bi},{version:4,factory:Fi},{version:5,factory:Li}],Va.extensionType=we.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...te("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...te("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...te("Approval",n)}))}};var Vs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...te("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...te("LogSetOwner",n)}))}};var js=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...te("Approval",i)}))}};var Rh=async(a,e)=>{let t=await wp(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new Vs(a,t);case wn.Erc20:return new Bn(a,t);case wn.Erc2612:return new js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new ne.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Ui.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new ne.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Vi.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new ne.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};ji.abi=Bp;var{AddressZero:Fp}=ht;var Hu=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(Fn.extensionType),e.address);if(t===Fp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return ne.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...te("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Cs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Ol);return[e,t,Fp,Ol,n,i,r,s]},async t=>({...te("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...te("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...te("MotionStaked",r),...te("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=ne.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...te("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...te("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await vi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...te("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...te("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.VotingReputation),t],async n=>({...te("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},ja=Fn;ja.supportedVersions=[{version:7,factory:Ui},{version:8,factory:Vi},{version:9,factory:ji}],ja.extensionType=we.VotingReputation;var W1={["motion"]:ja,["oneTx"]:Va},Or=class{static async connect(e,t){let n=await Ir(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Rh(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new na(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Va.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...te("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...te("DomainAdded",t),...te("FundingPotAdded",t),...te("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...te("DomainAdded",t),...te("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...te("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...te("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...te("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ta(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await vi(x,this.colony,r,s),_=await vi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...te("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...te("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...te("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=W1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Fa(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Ba(i),t.getLatestSupportedVersion()],async s=>({...ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return su(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...te("ColonyRoleSet",i),...te("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...te("ColonyRoleSet",i),...te("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...te("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...te("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...te("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...te("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...te("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...te("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...te("ArbitraryReputationUpdate",i)}))}},Br=Or;Br.supportedVersions=[{version:11,factory:Ni},{version:12,factory:Di},{version:13,factory:Oi}];var{splitSignature:K1}=ne,qu=class extends Ta{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=K1(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Hs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=_p(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...te("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...te("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Ph}=ne,{AddressZero:Lp}=ht,qs=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Nr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||ru[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Er[this.network]},this.networkContract=Ri.connect(t?.customNetworkAddress||iu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Hs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new Ta({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Pi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Lp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...te("TokenDeployed",r),...te("ColonyAdded",r),...te("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...te("TokenDeployed",r),...te("ColonyAdded",r),...te("TokenAuthorityDeployed",r)}))}async getColony(e){return Br.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Es[this.network],""):null}async getColonyAddress(e){let t=Ph(`${e}${Es[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Is[this.network],""):null}async getUserAddress(e){let t=Ph(`${e}${Is[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...te("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...te("TokenDeployed",i)}))}};var Nh=new ea.Web3Provider(window.ethereum),J1=async a=>new qs(a).getMetaColony(),$1=async()=>(await Nh.send("eth_requestAccounts",[]),Nh.getSigner()),Dh=document.querySelector("#button"),Vp=document.querySelector("#error"),Oh=document.querySelector("#result");if(!Dh||!Vp||!Oh)throw new Error("Could not find all required HTML elements");var Q1=a=>{Vp.innerText=a},X1=()=>{Vp.innerText=""},Up=a=>{Oh.innerText=a};Dh.addEventListener("click",async()=>{X1(),Up("Thinking...");try{let a=await $1(),e=await J1(a);Up(`Connected to metaColonyClient with version ${e.version}`)}catch(a){Q1(`Found an error: ${a.message}`),Up("")}});})(); +`)}`,e1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),fp=(a,e)=>{let t=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==pp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Re.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Mh(t.errors);throw new Error(n)};var Eh=(a,e)=>{let t=a===Re.Colony?e1(e):e,n=(i=>{let r=p=>{let f=E=>E.name==="colony"&&typeof E.data=="object"&&E.data!==null&&x(E.data)&&typeof E.version=="number",x=E=>typeof E.colonyName=="string"&&(E.colonyDisplayName===void 0||typeof E.colonyDisplayName=="string")&&(E.colonyAvatarHash===void 0||typeof E.colonyAvatarHash=="string")&&(E.colonyTokens===void 0||Array.isArray(E.colonyTokens)&&E.colonyTokens.every(J=>typeof J=="string"))&&(E.verifiedAddresses===void 0||Array.isArray(E.verifiedAddresses)&&E.verifiedAddresses.every(J=>typeof J=="string"))&&(E.isWhitelistActivated===void 0||typeof E.isWhitelistActivated=="boolean")&&(E.colonySafes===void 0||Array.isArray(E.colonySafes)&&E.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=E=>typeof E.chainId=="string"&&typeof E.contractAddress=="string"&&typeof E.moduleContractAddress=="string"&&typeof E.safeName=="string",_=E=>E.name==="domain"&&typeof E.data=="object"&&E.data!==null&&Array.isArray(E.data)===!1&&v(E.data)&&typeof E.version=="number",v=E=>(E.domainName===void 0||typeof E.domainName=="string")&&(E.domainColor===void 0||E.domainColor===0||E.domainColor===1||E.domainColor===2||E.domainColor===3||E.domainColor===4||E.domainColor===5||E.domainColor===6||E.domainColor===7||E.domainColor===8||E.domainColor===9||E.domainColor===10||E.domainColor===11||E.domainColor===12||E.domainColor===13||E.domainColor===14||E.domainColor===15)&&(E.domainPurpose===void 0||typeof E.domainPurpose=="string"),S=E=>E.name==="annotation"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.annotationMsg=="string"&&typeof E.version=="number",L=E=>E.name==="decision"&&typeof E.data=="object"&&E.data!==null&&O(E.data)&&typeof E.version=="number",O=E=>typeof E.title=="string"&&(E.description===void 0||typeof E.description=="string")&&typeof E.motionDomainId=="number",U=E=>E.name==="misc"&&typeof E.data=="object"&&E.data!==null&&typeof E.data.name=="string"&&typeof E.data.value=="string"&&typeof E.version=="number";return typeof p=="object"&&p!==null&&(E=>(()=>E.name==="colony"?f(E):E.name==="domain"?_(E):E.name==="annotation"?S(E):E.name==="decision"?L(E):E.name==="misc"?U(E):!1)())(p)},s=[],o=yp.default.validate.report(s);r(i)===!1&&((p,f,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&E(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),E=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,f+"",!0)||o(!0,{path:f+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:pp});if(!n.success){let i=Mh(n.errors);throw new Error(i)}return n.data};var cp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},mp=cp;var hp=(0,Ih.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),Fs={[Re.Annotation]:"Annotation(address,bytes32,string)",[Re.Colony]:"ColonyMetadata(address,string)",[Re.Decision]:"Annotation(address,bytes32,string)",[Re.Domain]:"DomainMetadata(address,uint256,string)",[Re.Misc]:"",[Re.DEFAULT]:""},Nr=class{adapter;constructor(e){this.adapter=e||new mp}static eventSupportsMetadata(e){return!!Object.keys(Fs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await hp(n)).json();return fp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await hp(n)).json(),s=Object.entries(Fs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return fp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await hp(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Eh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var DM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var xp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],Tn=class{static createInterface(){return new ne.Interface(xp)}static connect(e,t){return new oe(e,xp,t)}};xe(Tn,"abi",xp);var bp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],vn=class{static createInterface(){return new ne.Interface(bp)}static connect(e,t){return new oe(e,bp,t)}};xe(vn,"abi",bp);var gp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Ei=class{static createInterface(){return new ne.Interface(gp)}static connect(e,t){return new oe(e,gp,t)}};xe(Ei,"abi",gp);var Vu=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Ch="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",_1=a=>a.length>1,Dn=class extends ci{constructor(...e){_1(e)?super(...e):super(Vu,Ch,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new ne.Interface(Vu)}static connect(e,t){return new oe(e,Vu,t)}};xe(Dn,"bytecode",Ch),xe(Dn,"abi",Vu);var Tp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ii=class{static createInterface(){return new ne.Interface(Tp)}static connect(e,t){return new oe(e,Tp,t)}};xe(Ii,"abi",Tp);var vp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Ci=class{static createInterface(){return new ne.Interface(vp)}static connect(e,t){return new oe(e,vp,t)}};xe(Ci,"abi",vp);var Si;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Si||(Si={}));var wn;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(wn||(wn={}));var{AddressZero:Sh}=ht;async function M1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var E1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Dn.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await M1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Sh)}catch{i=!1}try{await t.nonces(Sh)}catch{r=!1}return n?i?t.tokenClientType=wn.Colony:(t=Ii.connect(a,e),t.tokenClientType=wn.ColonyLegacy):r?(t=vn.connect(a,e),t.tokenClientType=wn.Erc2612):(t=Tn.connect(a,e),t.tokenClientType=wn.Erc20),t.clientType=Si.TokenClient,t},wp=E1;var I1=(a,e)=>{let t=Ci.connect(a,e);return t.clientType=Si.TokenLockingClient,t},_p=I1;var{AddressZero:kp}=ht,C1=Tn.connect(kp,new ea.BaseProvider(3656691)).interface,S1=Ei.connect(kp,new ea.BaseProvider(3656691)).interface,R1=vn.connect(kp,new ea.BaseProvider(3656691)).interface;var Ap=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Ls=class{static createInterface(){return new ne.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};Ls.abi=Ap;var Mp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Us=class{static createInterface(){return new ne.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};Us.abi=Mp;var Ep=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Ri=class{static createInterface(){return new ne.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};Ri.abi=Ep;var Ta=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,Fs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:N1,solidityKeccak256:D1,splitSignature:O1}=ne,Pi=class extends Ta{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Nn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=D1(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=N1(l),f=await n.signMessage(p),{r:x,s:C,v:_}=O1(f),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var te=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Ip=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ni=class{static createInterface(){return new ne.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};Ni.abi=Ip;var Cp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new ne.Interface(Cp)}static connect(e,t){return new oe(e,Cp,t)}};Di.abi=Cp;var Sp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Oi=class{static createInterface(){return new ne.Interface(Sp)}static connect(e,t){return new oe(e,Sp,t)}};Oi.abi=Sp;var Rp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Bi=class{static createInterface(){return new ne.Interface(Rp)}static connect(e,t){return new oe(e,Rp,t)}};Bi.abi=Rp;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Fi=class{static createInterface(){return new ne.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Fi.abi=Pp;var Np=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Li=class{static createInterface(){return new ne.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Li.abi=Np;var{AddressZero:H1}=ht,On=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(On.extensionType),e.address);if(t===H1)throw new Error(`${On.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(On.extensionType,n,e.version))throw new Error(`Version ${n} of the ${On.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=On.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${On.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new On(e,r,n)}static getLatestSupportedVersion(){return On.supportedVersions[On.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let f=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding],this.oneTxPaymentContract.address),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[vt.Administration,vt.Funding]);return[_,v,S,L,f,C,x,s,ke.SkillIgnore]},async _=>({...te("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.OneTxPayment),t],async n=>({...te("ExtensionUpgraded",n)}))}},Va=On;Va.supportedVersions=[{version:3,factory:Bi},{version:4,factory:Fi},{version:5,factory:Li}],Va.extensionType=we.OneTxPayment;var Bn=class{constructor(e,t){typeof t=="string"?this.tokenClient=Tn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...te("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...te("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...te("Approval",n)}))}};var Vs=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Dn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...te("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...te("LogSetOwner",n)}))}};var js=class extends Bn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=vn.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...te("Approval",i)}))}};var Rh=async(a,e)=>{let t=await wp(e,a.signerOrProvider);switch(t.tokenClientType){case wn.Colony:return new Vs(a,t);case wn.Erc20:return new Bn(a,t);case wn.Erc2612:return new js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Ui=class{static createInterface(){return new ne.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Ui.abi=Dp;var Op=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Vi=class{static createInterface(){return new ne.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Vi.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new ne.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};ji.abi=Bp;var{AddressZero:Fp}=ht;var Hu=F.from(10).pow(18),Fn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(Ba(Fn.extensionType),e.address);if(t===Fp)throw new Error(`${Fn.extensionType} extension is not installed for this Colony`);let n=await Ir(t,e.colonyNetwork.signerOrProvider);if(!Fa(Fn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Fn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Fn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Fn(e,r,n)}static getLatestSupportedVersion(){return Fn.supportedVersions[Fn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return ne.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...te("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Cs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,Fp,Ol);return[e,t,Fp,Ol,n,i,r,s]},async t=>({...te("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Re.Decision,t),[e,n]},async n=>({...te("Annotation",n)}),{metadataType:Re.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==zt.Staking)throw new Error(`Motion cannot be staked. It's currently in "${zt[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Ul(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ta(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,vt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:E,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,E,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...te("MotionStaked",r),...te("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:f,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=ne.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,f,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...te("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),f=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,f,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,f,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...te("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==zt.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${zt[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await vi(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:f,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,f,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...te("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==zt.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${zt[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...te("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[Ba(we.VotingReputation),t],async n=>({...te("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},ja=Fn;ja.supportedVersions=[{version:7,factory:Ui},{version:8,factory:Vi},{version:9,factory:ji}],ja.extensionType=we.VotingReputation;var W1={["motion"]:ja,["oneTx"]:Va},Or=class{static async connect(e,t){let n=await Ir(t,e.signerOrProvider),i=Or.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Rh(e,s),l=new Or(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Or.supportedVersions[Or.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new na(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new Dr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await ja.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Va.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Bn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Colony,e),[t]},async t=>({...te("ColonyMetadata",t)}),{metadataType:Re.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...te("DomainAdded",t),...te("FundingPotAdded",t),...te("DomainMetadata",t)}),{metadataType:Re.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...te("DomainAdded",t),...te("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Re.Domain,e),[ke.RootDomain,t]},{roles:vt.Architecture,domain:ke.RootDomain},async t=>({...te("DomainMetadata",t)}),{metadataType:Re.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:vt.Architecture,domain:e},async n=>({...te("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...te("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,f]=await ta(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,vt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await vi(x,this.colony,r,s),_=await vi(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,f,r,C,_,v,S,e,o]},async l=>({...te("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...te("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Re.Annotation,t),[e,n]},async n=>({...te("Annotation",n)}),{metadataType:Re.Annotation})}installExtension(e){let t=W1[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Fa(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[Ba(i),t.getLatestSupportedVersion()],async s=>({...ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return su(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...te("ColonyRoleSet",i),...te("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Vl(r);return[e,n,s]},{roles:vt.Architecture,domain:n},async i=>({...te("ColonyRoleSet",i),...te("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...te("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...te("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...te("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...te("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...te("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...te("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:vt.Arbitration},async i=>({...te("ArbitraryReputationUpdate",i)}))}},Br=Or;Br.supportedVersions=[{version:11,factory:Ni},{version:12,factory:Di},{version:13,factory:Oi}];var{splitSignature:K1}=ne,qu=class extends Ta{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Nn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),f=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:f}),{r:C,s:_,v}=K1(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:f,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var Hs=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=_p(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...te("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...te("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:Ph}=ne,{AddressZero:Lp}=ht,qs=class{constructor(e,t){this.network=t?.network||Nn.Gnosis,this.ipfs=new Nr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||ru[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Er[this.network]},this.networkContract=Ri.connect(t?.customNetworkAddress||iu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof St))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new Hs(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new Ta({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Pi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Lp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Re.Colony,n),r},async r=>({...te("TokenDeployed",r),...te("ColonyAdded",r),...te("TokenAuthorityDeployed",r)}),{metadataType:Re.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...te("TokenDeployed",r),...te("ColonyAdded",r),...te("TokenAuthorityDeployed",r)}))}async getColony(e){return Br.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Es[this.network],""):null}async getColonyAddress(e){let t=Ph(`${e}${Es[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Is[this.network],""):null}async getUserAddress(e){let t=Ph(`${e}${Is[this.network]}`),n=await this.networkContract.addr(t);return n!==Lp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...te("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...te("TokenDeployed",i)}))}};var Nh=new ea.Web3Provider(window.ethereum),J1=async a=>new qs(a).getMetaColony(),$1=async()=>(await Nh.send("eth_requestAccounts",[]),Nh.getSigner()),Dh=document.querySelector("#button"),Vp=document.querySelector("#error"),Oh=document.querySelector("#result");if(!Dh||!Vp||!Oh)throw new Error("Could not find all required HTML elements");var Q1=a=>{Vp.innerText=a},X1=()=>{Vp.innerText=""},Up=a=>{Oh.innerText=a};Dh.addEventListener("click",async()=>{X1(),Up("Thinking...");try{let a=await $1(),e=await J1(a);Up(`Connected to metaColonyClient with version ${e.version}`)}catch(a){Q1(`Found an error: ${a.message}`),Up("")}});})(); /** * [js-sha3]{@link https://github.com/emn178/js-sha3} * diff --git a/motions.js b/motions.js index 55f9bb708..ec6a0f58f 100644 --- a/motions.js +++ b/motions.js @@ -3,7 +3,7 @@ `)+` `)}static register(e,t){if(t||(t=e.locale),ix)try{let n=window;n._ethers&&n._ethers.wordlists&&(n._ethers.wordlists[t]||B(n._ethers.wordlists,t,e))}catch{}}};var rx="AbandonAbilityAbleAboutAboveAbsentAbsorbAbstractAbsurdAbuseAccessAccidentAccountAccuseAchieveAcidAcousticAcquireAcrossActActionActorActressActualAdaptAddAddictAddressAdjustAdmitAdultAdvanceAdviceAerobicAffairAffordAfraidAgainAgeAgentAgreeAheadAimAirAirportAisleAlarmAlbumAlcoholAlertAlienAllAlleyAllowAlmostAloneAlphaAlreadyAlsoAlterAlwaysAmateurAmazingAmongAmountAmusedAnalystAnchorAncientAngerAngleAngryAnimalAnkleAnnounceAnnualAnotherAnswerAntennaAntiqueAnxietyAnyApartApologyAppearAppleApproveAprilArchArcticAreaArenaArgueArmArmedArmorArmyAroundArrangeArrestArriveArrowArtArtefactArtistArtworkAskAspectAssaultAssetAssistAssumeAsthmaAthleteAtomAttackAttendAttitudeAttractAuctionAuditAugustAuntAuthorAutoAutumnAverageAvocadoAvoidAwakeAwareAwayAwesomeAwfulAwkwardAxisBabyBachelorBaconBadgeBagBalanceBalconyBallBambooBananaBannerBarBarelyBargainBarrelBaseBasicBasketBattleBeachBeanBeautyBecauseBecomeBeefBeforeBeginBehaveBehindBelieveBelowBeltBenchBenefitBestBetrayBetterBetweenBeyondBicycleBidBikeBindBiologyBirdBirthBitterBlackBladeBlameBlanketBlastBleakBlessBlindBloodBlossomBlouseBlueBlurBlushBoardBoatBodyBoilBombBoneBonusBookBoostBorderBoringBorrowBossBottomBounceBoxBoyBracketBrainBrandBrassBraveBreadBreezeBrickBridgeBriefBrightBringBriskBroccoliBrokenBronzeBroomBrotherBrownBrushBubbleBuddyBudgetBuffaloBuildBulbBulkBulletBundleBunkerBurdenBurgerBurstBusBusinessBusyButterBuyerBuzzCabbageCabinCableCactusCageCakeCallCalmCameraCampCanCanalCancelCandyCannonCanoeCanvasCanyonCapableCapitalCaptainCarCarbonCardCargoCarpetCarryCartCaseCashCasinoCastleCasualCatCatalogCatchCategoryCattleCaughtCauseCautionCaveCeilingCeleryCementCensusCenturyCerealCertainChairChalkChampionChangeChaosChapterChargeChaseChatCheapCheckCheeseChefCherryChestChickenChiefChildChimneyChoiceChooseChronicChuckleChunkChurnCigarCinnamonCircleCitizenCityCivilClaimClapClarifyClawClayCleanClerkCleverClickClientCliffClimbClinicClipClockClogCloseClothCloudClownClubClumpClusterClutchCoachCoastCoconutCodeCoffeeCoilCoinCollectColorColumnCombineComeComfortComicCommonCompanyConcertConductConfirmCongressConnectConsiderControlConvinceCookCoolCopperCopyCoralCoreCornCorrectCostCottonCouchCountryCoupleCourseCousinCoverCoyoteCrackCradleCraftCramCraneCrashCraterCrawlCrazyCreamCreditCreekCrewCricketCrimeCrispCriticCropCrossCrouchCrowdCrucialCruelCruiseCrumbleCrunchCrushCryCrystalCubeCultureCupCupboardCuriousCurrentCurtainCurveCushionCustomCuteCycleDadDamageDampDanceDangerDaringDashDaughterDawnDayDealDebateDebrisDecadeDecemberDecideDeclineDecorateDecreaseDeerDefenseDefineDefyDegreeDelayDeliverDemandDemiseDenialDentistDenyDepartDependDepositDepthDeputyDeriveDescribeDesertDesignDeskDespairDestroyDetailDetectDevelopDeviceDevoteDiagramDialDiamondDiaryDiceDieselDietDifferDigitalDignityDilemmaDinnerDinosaurDirectDirtDisagreeDiscoverDiseaseDishDismissDisorderDisplayDistanceDivertDivideDivorceDizzyDoctorDocumentDogDollDolphinDomainDonateDonkeyDonorDoorDoseDoubleDoveDraftDragonDramaDrasticDrawDreamDressDriftDrillDrinkDripDriveDropDrumDryDuckDumbDuneDuringDustDutchDutyDwarfDynamicEagerEagleEarlyEarnEarthEasilyEastEasyEchoEcologyEconomyEdgeEditEducateEffortEggEightEitherElbowElderElectricElegantElementElephantElevatorEliteElseEmbarkEmbodyEmbraceEmergeEmotionEmployEmpowerEmptyEnableEnactEndEndlessEndorseEnemyEnergyEnforceEngageEngineEnhanceEnjoyEnlistEnoughEnrichEnrollEnsureEnterEntireEntryEnvelopeEpisodeEqualEquipEraEraseErodeErosionErrorEruptEscapeEssayEssenceEstateEternalEthicsEvidenceEvilEvokeEvolveExactExampleExcessExchangeExciteExcludeExcuseExecuteExerciseExhaustExhibitExileExistExitExoticExpandExpectExpireExplainExposeExpressExtendExtraEyeEyebrowFabricFaceFacultyFadeFaintFaithFallFalseFameFamilyFamousFanFancyFantasyFarmFashionFatFatalFatherFatigueFaultFavoriteFeatureFebruaryFederalFeeFeedFeelFemaleFenceFestivalFetchFeverFewFiberFictionFieldFigureFileFilmFilterFinalFindFineFingerFinishFireFirmFirstFiscalFishFitFitnessFixFlagFlameFlashFlatFlavorFleeFlightFlipFloatFlockFloorFlowerFluidFlushFlyFoamFocusFogFoilFoldFollowFoodFootForceForestForgetForkFortuneForumForwardFossilFosterFoundFoxFragileFrameFrequentFreshFriendFringeFrogFrontFrostFrownFrozenFruitFuelFunFunnyFurnaceFuryFutureGadgetGainGalaxyGalleryGameGapGarageGarbageGardenGarlicGarmentGasGaspGateGatherGaugeGazeGeneralGeniusGenreGentleGenuineGestureGhostGiantGiftGiggleGingerGiraffeGirlGiveGladGlanceGlareGlassGlideGlimpseGlobeGloomGloryGloveGlowGlueGoatGoddessGoldGoodGooseGorillaGospelGossipGovernGownGrabGraceGrainGrantGrapeGrassGravityGreatGreenGridGriefGritGroceryGroupGrowGruntGuardGuessGuideGuiltGuitarGunGymHabitHairHalfHammerHamsterHandHappyHarborHardHarshHarvestHatHaveHawkHazardHeadHealthHeartHeavyHedgehogHeightHelloHelmetHelpHenHeroHiddenHighHillHintHipHireHistoryHobbyHockeyHoldHoleHolidayHollowHomeHoneyHoodHopeHornHorrorHorseHospitalHostHotelHourHoverHubHugeHumanHumbleHumorHundredHungryHuntHurdleHurryHurtHusbandHybridIceIconIdeaIdentifyIdleIgnoreIllIllegalIllnessImageImitateImmenseImmuneImpactImposeImproveImpulseInchIncludeIncomeIncreaseIndexIndicateIndoorIndustryInfantInflictInformInhaleInheritInitialInjectInjuryInmateInnerInnocentInputInquiryInsaneInsectInsideInspireInstallIntactInterestIntoInvestInviteInvolveIronIslandIsolateIssueItemIvoryJacketJaguarJarJazzJealousJeansJellyJewelJobJoinJokeJourneyJoyJudgeJuiceJumpJungleJuniorJunkJustKangarooKeenKeepKetchupKeyKickKidKidneyKindKingdomKissKitKitchenKiteKittenKiwiKneeKnifeKnockKnowLabLabelLaborLadderLadyLakeLampLanguageLaptopLargeLaterLatinLaughLaundryLavaLawLawnLawsuitLayerLazyLeaderLeafLearnLeaveLectureLeftLegLegalLegendLeisureLemonLendLengthLensLeopardLessonLetterLevelLiarLibertyLibraryLicenseLifeLiftLightLikeLimbLimitLinkLionLiquidListLittleLiveLizardLoadLoanLobsterLocalLockLogicLonelyLongLoopLotteryLoudLoungeLoveLoyalLuckyLuggageLumberLunarLunchLuxuryLyricsMachineMadMagicMagnetMaidMailMainMajorMakeMammalManManageMandateMangoMansionManualMapleMarbleMarchMarginMarineMarketMarriageMaskMassMasterMatchMaterialMathMatrixMatterMaximumMazeMeadowMeanMeasureMeatMechanicMedalMediaMelodyMeltMemberMemoryMentionMenuMercyMergeMeritMerryMeshMessageMetalMethodMiddleMidnightMilkMillionMimicMindMinimumMinorMinuteMiracleMirrorMiseryMissMistakeMixMixedMixtureMobileModelModifyMomMomentMonitorMonkeyMonsterMonthMoonMoralMoreMorningMosquitoMotherMotionMotorMountainMouseMoveMovieMuchMuffinMuleMultiplyMuscleMuseumMushroomMusicMustMutualMyselfMysteryMythNaiveNameNapkinNarrowNastyNationNatureNearNeckNeedNegativeNeglectNeitherNephewNerveNestNetNetworkNeutralNeverNewsNextNiceNightNobleNoiseNomineeNoodleNormalNorthNoseNotableNoteNothingNoticeNovelNowNuclearNumberNurseNutOakObeyObjectObligeObscureObserveObtainObviousOccurOceanOctoberOdorOffOfferOfficeOftenOilOkayOldOliveOlympicOmitOnceOneOnionOnlineOnlyOpenOperaOpinionOpposeOptionOrangeOrbitOrchardOrderOrdinaryOrganOrientOriginalOrphanOstrichOtherOutdoorOuterOutputOutsideOvalOvenOverOwnOwnerOxygenOysterOzonePactPaddlePagePairPalacePalmPandaPanelPanicPantherPaperParadeParentParkParrotPartyPassPatchPathPatientPatrolPatternPausePavePaymentPeacePeanutPearPeasantPelicanPenPenaltyPencilPeoplePepperPerfectPermitPersonPetPhonePhotoPhrasePhysicalPianoPicnicPicturePiecePigPigeonPillPilotPinkPioneerPipePistolPitchPizzaPlacePlanetPlasticPlatePlayPleasePledgePluckPlugPlungePoemPoetPointPolarPolePolicePondPonyPoolPopularPortionPositionPossiblePostPotatoPotteryPovertyPowderPowerPracticePraisePredictPreferPreparePresentPrettyPreventPricePridePrimaryPrintPriorityPrisonPrivatePrizeProblemProcessProduceProfitProgramProjectPromoteProofPropertyProsperProtectProudProvidePublicPuddingPullPulpPulsePumpkinPunchPupilPuppyPurchasePurityPurposePursePushPutPuzzlePyramidQualityQuantumQuarterQuestionQuickQuitQuizQuoteRabbitRaccoonRaceRackRadarRadioRailRainRaiseRallyRampRanchRandomRangeRapidRareRateRatherRavenRawRazorReadyRealReasonRebelRebuildRecallReceiveRecipeRecordRecycleReduceReflectReformRefuseRegionRegretRegularRejectRelaxReleaseReliefRelyRemainRememberRemindRemoveRenderRenewRentReopenRepairRepeatReplaceReportRequireRescueResembleResistResourceResponseResultRetireRetreatReturnReunionRevealReviewRewardRhythmRibRibbonRiceRichRideRidgeRifleRightRigidRingRiotRippleRiskRitualRivalRiverRoadRoastRobotRobustRocketRomanceRoofRookieRoomRoseRotateRoughRoundRouteRoyalRubberRudeRugRuleRunRunwayRuralSadSaddleSadnessSafeSailSaladSalmonSalonSaltSaluteSameSampleSandSatisfySatoshiSauceSausageSaveSayScaleScanScareScatterSceneSchemeSchoolScienceScissorsScorpionScoutScrapScreenScriptScrubSeaSearchSeasonSeatSecondSecretSectionSecuritySeedSeekSegmentSelectSellSeminarSeniorSenseSentenceSeriesServiceSessionSettleSetupSevenShadowShaftShallowShareShedShellSheriffShieldShiftShineShipShiverShockShoeShootShopShortShoulderShoveShrimpShrugShuffleShySiblingSickSideSiegeSightSignSilentSilkSillySilverSimilarSimpleSinceSingSirenSisterSituateSixSizeSkateSketchSkiSkillSkinSkirtSkullSlabSlamSleepSlenderSliceSlideSlightSlimSloganSlotSlowSlushSmallSmartSmileSmokeSmoothSnackSnakeSnapSniffSnowSoapSoccerSocialSockSodaSoftSolarSoldierSolidSolutionSolveSomeoneSongSoonSorrySortSoulSoundSoupSourceSouthSpaceSpareSpatialSpawnSpeakSpecialSpeedSpellSpendSphereSpiceSpiderSpikeSpinSpiritSplitSpoilSponsorSpoonSportSpotSpraySpreadSpringSpySquareSqueezeSquirrelStableStadiumStaffStageStairsStampStandStartStateStaySteakSteelStemStepStereoStickStillStingStockStomachStoneStoolStoryStoveStrategyStreetStrikeStrongStruggleStudentStuffStumbleStyleSubjectSubmitSubwaySuccessSuchSuddenSufferSugarSuggestSuitSummerSunSunnySunsetSuperSupplySupremeSureSurfaceSurgeSurpriseSurroundSurveySuspectSustainSwallowSwampSwapSwarmSwearSweetSwiftSwimSwingSwitchSwordSymbolSymptomSyrupSystemTableTackleTagTailTalentTalkTankTapeTargetTaskTasteTattooTaxiTeachTeamTellTenTenantTennisTentTermTestTextThankThatThemeThenTheoryThereTheyThingThisThoughtThreeThriveThrowThumbThunderTicketTideTigerTiltTimberTimeTinyTipTiredTissueTitleToastTobaccoTodayToddlerToeTogetherToiletTokenTomatoTomorrowToneTongueTonightToolToothTopTopicToppleTorchTornadoTortoiseTossTotalTouristTowardTowerTownToyTrackTradeTrafficTragicTrainTransferTrapTrashTravelTrayTreatTreeTrendTrialTribeTrickTriggerTrimTripTrophyTroubleTruckTrueTrulyTrumpetTrustTruthTryTubeTuitionTumbleTunaTunnelTurkeyTurnTurtleTwelveTwentyTwiceTwinTwistTwoTypeTypicalUglyUmbrellaUnableUnawareUncleUncoverUnderUndoUnfairUnfoldUnhappyUniformUniqueUnitUniverseUnknownUnlockUntilUnusualUnveilUpdateUpgradeUpholdUponUpperUpsetUrbanUrgeUsageUseUsedUsefulUselessUsualUtilityVacantVacuumVagueValidValleyValveVanVanishVaporVariousVastVaultVehicleVelvetVendorVentureVenueVerbVerifyVersionVeryVesselVeteranViableVibrantViciousVictoryVideoViewVillageVintageViolinVirtualVirusVisaVisitVisualVitalVividVocalVoiceVoidVolcanoVolumeVoteVoyageWageWagonWaitWalkWallWalnutWantWarfareWarmWarriorWashWaspWasteWaterWaveWayWealthWeaponWearWeaselWeatherWebWeddingWeekendWeirdWelcomeWestWetWhaleWhatWheatWheelWhenWhereWhipWhisperWideWidthWifeWildWillWinWindowWineWingWinkWinnerWinterWireWisdomWiseWishWitnessWolfWomanWonderWoodWoolWordWorkWorldWorryWorthWrapWreckWrestleWristWriteWrongYardYearYellowYouYoungYouthZebraZeroZoneZoo",ds=null;function xc(a){if(ds==null&&(ds=rx.replace(/([A-Z])/g," $1").toLowerCase().substring(1).split(" "),Tn.check(a)!=="0x3c8acc1e7b08d8e76f9fda015ef48dc8c710a73cb7e0f77b2c18a9b5a7adde60"))throw ds=null,new Error("BIP39 Wordlist for en (English) FAILED")}var ul=class extends Tn{constructor(){super("en")}getWord(e){return xc(this),ds[e]}getWordIndex(e){return xc(this),ds.indexOf(e)}},dl=new ul;Tn.register(dl);var vi={en:dl};var bc="hdnode/5.7.0";var ls=new E(bc),sx=F.from("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),ox=ve("Bitcoin seed"),gr=2147483648;function Tc(a){return(1<=256)throw new Error("Depth too large!");return gc(ye([this.privateKey!=null?"0x0488ADE4":"0x0488B21E",W(this.depth),this.parentFingerprint,me(W(this.index),4),this.chainCode,this.privateKey!=null?ye(["0x00",this.privateKey]):this.publicKey]))}neuter(){return new Ct(br,null,this.publicKey,this.parentFingerprint,this.chainCode,this.index,this.depth,this.path)}_derive(e){if(e>4294967295)throw new Error("invalid index - "+String(e));let t=this.path;t&&(t+="/"+(e&~gr));let n=new Uint8Array(37);if(e&gr){if(!this.privateKey)throw new Error("cannot derive child of neutered node");n.set(j(this.privateKey),1),t&&(t+="'")}else n.set(j(this.publicKey));for(let x=24;x>=0;x-=8)n[33+(x>>3)]=e>>24-x&255;let i=j(xa(ea.sha512,this.chainCode,n)),r=i.slice(0,32),s=i.slice(32),o=null,l=null;this.privateKey?o=jo(F.from(r).add(this.privateKey).mod(sx)):l=new bn(W(r))._addPoint(this.publicKey);let p=t,c=this.mnemonic;return c&&(p=Object.freeze({phrase:c.phrase,path:t,locale:c.locale||"en"})),new Ct(br,o,l,this.fingerprint,jo(s),e,this.depth+1,p)}derivePath(e){let t=e.split("/");if(t.length===0||t[0]==="m"&&this.depth!==0)throw new Error("invalid path - "+e);t[0]==="m"&&t.shift();let n=this;for(let i=0;i=gr)throw new Error("invalid path index - "+r);n=n._derive(gr+s)}else if(r.match(/^[0-9]+$/)){let s=parseInt(r);if(s>=gr)throw new Error("invalid path index - "+r);n=n._derive(s)}else throw new Error("invalid path component - "+r)}return n}static _fromSeed(e,t){let n=j(e);if(n.length<16||n.length>64)throw new Error("invalid seed");let i=j(xa(ea.sha512,ox,n));return new Ct(br,jo(i.slice(0,32)),null,"0x00000000",jo(i.slice(32)),0,0,t)}static fromMnemonic(e,t,n){return n=ll(n),e=wi(Tr(e,n),n),Ct._fromSeed(pl(e,t),{phrase:e,path:"m",locale:n.locale})}static fromSeed(e){return Ct._fromSeed(e,null)}static fromExtendedKey(e){let t=ha.decode(e);(t.length!==82||gc(t.slice(0,78))!==e)&&ls.throwArgumentError("invalid extended key","extendedKey","[REDACTED]");let n=t[4],i=W(t.slice(5,9)),r=parseInt(W(t.slice(9,13)).substring(2),16),s=W(t.slice(13,45)),o=t.slice(45,78);switch(W(t.slice(0,4))){case"0x0488b21e":case"0x043587cf":return new Ct(br,null,W(o),i,s,r,n,null);case"0x0488ade4":case"0x04358394 ":if(o[0]!==0)break;return new Ct(br,W(o.slice(1)),null,i,s,r,n,null)}return ls.throwArgumentError("invalid extended key","extendedKey","[REDACTED]")}};function pl(a,e){e||(e="");let t=ve("mnemonic"+e,Jt.NFKD);return Ti(ve(a,Jt.NFKD),t,2048,64,"sha512")}function Tr(a,e){e=ll(e),ls.checkNormalize();let t=e.split(a);if(t.length%3!==0)throw new Error("invalid mnemonic");let n=j(new Uint8Array(Math.ceil(11*t.length/8))),i=0;for(let p=0;p>3]|=1<<7-i%8),i++}let r=32*t.length/3,s=t.length/3,o=Tc(s);if((j(en(n.slice(0,r/8)))[0]&o)!==(n[n.length-1]&o))throw new Error("invalid checksum");return W(n.slice(0,r/8))}function wi(a,e){if(e=ll(e),a=j(a),a.length%4!==0||a.length<16||a.length>32)throw new Error("invalid entropy");let t=[0],n=11;for(let s=0;s8?(t[t.length-1]<<=8,t[t.length-1]|=a[s],n-=8):(t[t.length-1]<<=n,t[t.length-1]|=a[s]>>8-n,t.push(a[s]&ux(8-n)),n+=3);let i=a.length/4,r=j(en(a))[0]&Tc(i);return t[t.length-1]<<=i,t[t.length-1]|=r>>8-i,e.join(t.map(s=>e.getWord(s)))}function vc(a,e){try{return Tr(a,e),!0}catch{}return!1}function wc(a){return(typeof a!="number"||a<0||a>=gr||a%1)&&ls.throwArgumentError("invalid account index","index",a),`m/44'/60'/${a}'/0/0`}var _c="random/5.7.0";var yl=new E(_c);function dx(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}var kc=dx(),Ho=kc.crypto||kc.msCrypto;(!Ho||!Ho.getRandomValues)&&(yl.warn("WARNING: Missing strong random number source"),Ho={getRandomValues:function(a){return yl.throwError("no secure random source avaialble",E.errors.UNSUPPORTED_OPERATION,{operation:"crypto.getRandomValues"})}});function ta(a){(a<=0||a>1024||a%1||a!=a)&&yl.throwArgumentError("invalid length","length",a);let e=new Uint8Array(a);return Ho.getRandomValues(e),j(e)}function ps(a){a=a.slice();for(let e=a.length-1;e>0;e--){let t=Math.floor(Math.random()*(e+1)),n=a[e];a[e]=a[t],a[t]=n}return a}var ml=Mn(fl());var qo="json-wallets/5.7.0";function ga(a){return typeof a=="string"&&a.substring(0,2)!=="0x"&&(a="0x"+a),j(a)}function vr(a,e){for(a=String(a);a.length{L=j(L);let O=L.slice(0,16),U=L.slice(16,32),H=L.slice(32,64),M=new Ta.default.Counter(x),J=new Ta.default.ModeOfOperation.ctr(O,M),$=j(J.encrypt(i)),de=ce(ye([U,$])),T={address:a.address.substring(2).toLowerCase(),id:Ec(C),version:3,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:W(x).substring(2)},ciphertext:W($).substring(2),kdf:"scrypt",kdfparams:{salt:W(c).substring(2),n:_,dklen:32,p:S,r:v},mac:de.substring(2)}};if(s){let R=ta(16),N=new Ta.default.Counter(R),q=new Ta.default.ModeOfOperation.ctr(H,N),se=j(q.encrypt(s)),I=new Date,u=I.getUTCFullYear()+"-"+vr(I.getUTCMonth()+1,2)+"-"+vr(I.getUTCDate(),2)+"T"+vr(I.getUTCHours(),2)+"-"+vr(I.getUTCMinutes(),2)+"-"+vr(I.getUTCSeconds(),2)+".0Z";T["x-ethers"]={client:p,gethFilename:"UTC--"+u+"--"+T.address,mnemonicCounter:W(R).substring(2),mnemonicCiphertext:W(se).substring(2),path:o,locale:l,version:"0.1"}}return JSON.stringify(T)})}function Oc(a,e,t){if(zo(a)){t&&t(0);let n=xl(a,e);return t&&t(1),Promise.resolve(n)}return Go(a)?Dc(a,e,t):Promise.reject(new Error("invalid JSON wallet"))}function Bc(a,e){if(zo(a))return xl(a,e);if(Go(a))return Nc(a,e);throw new Error("invalid JSON wallet")}var Fc="wallet/5.7.0";var Lc=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},wr=new E(Fc);function fx(a){return a!=null&&ie(a.privateKey,32)&&a.address!=null}function mx(a){let e=a.mnemonic;return e&&e.phrase}var Nn=class extends Pt{constructor(e,t){if(super(),fx(e)){let n=new bn(e.privateKey);if(B(this,"_signingKey",()=>n),B(this,"address",gn(this.publicKey)),this.address!==fe(e.address)&&wr.throwArgumentError("privateKey/address mismatch","privateKey","[REDACTED]"),mx(e)){let i=e.mnemonic;B(this,"_mnemonic",()=>({phrase:i.phrase,path:i.path||ba,locale:i.locale||"en"}));let r=this.mnemonic,s=Ct.fromMnemonic(r.phrase,null,r.locale).derivePath(r.path);gn(s.privateKey)!==this.address&&wr.throwArgumentError("mnemonic/address mismatch","privateKey","[REDACTED]")}else B(this,"_mnemonic",()=>null)}else{if(bn.isSigningKey(e))e.curve!=="secp256k1"&&wr.throwArgumentError("unsupported curve; must be secp256k1","privateKey","[REDACTED]"),B(this,"_signingKey",()=>e);else{typeof e=="string"&&e.match(/^[0-9a-f]*$/i)&&e.length===64&&(e="0x"+e);let n=new bn(e);B(this,"_signingKey",()=>n)}B(this,"_mnemonic",()=>null),B(this,"address",gn(this.publicKey))}t&&!Xt.isProvider(t)&&wr.throwArgumentError("invalid provider","provider",t),B(this,"provider",t||null)}get mnemonic(){return this._mnemonic()}get privateKey(){return this._signingKey().privateKey}get publicKey(){return this._signingKey().publicKey}getAddress(){return Promise.resolve(this.address)}connect(e){return new Nn(this,e)}signTransaction(e){return Se(e).then(t=>{t.from!=null&&(fe(t.from)!==this.address&&wr.throwArgumentError("transaction from address mismatch","transaction.from",e.from),delete t.from);let n=this._signingKey().signDigest(ce(ss(t)));return ss(t,n)})}signMessage(e){return Lc(this,void 0,void 0,function*(){return zr(this._signingKey().signDigest(rr(e)))})}_signTypedData(e,t,n){return Lc(this,void 0,void 0,function*(){let i=yield gt.resolveNames(e,t,n,r=>(this.provider==null&&wr.throwError("cannot resolve ENS names without a provider",E.errors.UNSUPPORTED_OPERATION,{operation:"resolveName",value:r}),this.provider.resolveName(r)));return zr(this._signingKey().signDigest(gt.hash(i.domain,t,i.value)))})}encrypt(e,t,n){if(typeof t=="function"&&!n&&(n=t,t={}),n&&typeof n!="function")throw new Error("invalid callback");return t||(t={}),wl(this,e,t,n)}static createRandom(e){let t=ta(16);e||(e={}),e.extraEntropy&&(t=j(Ce(ce(ye([t,e.extraEntropy])),0,16)));let n=wi(t,e.locale);return Nn.fromMnemonic(n,e.path,e.locale)}static fromEncryptedJson(e,t,n){return Oc(e,t,n).then(i=>new Nn(i))}static fromEncryptedJsonSync(e,t){return new Nn(Bc(e,t))}static fromMnemonic(e,t,n){return t||(t=ba),new Nn(Ct.fromMnemonic(e,null,n).derivePath(t))}};function Uc(a,e){return xi(rr(a),e)}function Vc(a,e,t,n){return xi(gt.hash(a,e,t),n)}var ia={};Ki(ia,{AlchemyProvider:()=>Ir,AlchemyWebSocketProvider:()=>_s,AnkrProvider:()=>ks,BaseProvider:()=>aa,CloudflareProvider:()=>As,EtherscanProvider:()=>Es,FallbackProvider:()=>Is,Formatter:()=>X,InfuraProvider:()=>Sr,InfuraWebSocketProvider:()=>Ss,IpcProvider:()=>Ol,JsonRpcBatchProvider:()=>ou,JsonRpcProvider:()=>tn,JsonRpcSigner:()=>Er,NodesmithProvider:()=>Rs,PocketProvider:()=>Ps,Provider:()=>Xt,Resolver:()=>Ar,StaticJsonRpcProvider:()=>ws,UrlJsonRpcProvider:()=>St,Web3Provider:()=>Ns,WebSocketProvider:()=>_a,getDefaultProvider:()=>uu,getNetwork:()=>cs,isCommunityResourcable:()=>Al,isCommunityResource:()=>hs,showThrottleMessage:()=>na});var jc="networks/5.7.1";var Hc=new E(jc);function hx(a){return a&&typeof a.renetwork=="function"}function va(a){let e=function(t,n){n==null&&(n={});let i=[];if(t.InfuraProvider&&n.infura!=="-")try{i.push(new t.InfuraProvider(a,n.infura))}catch{}if(t.EtherscanProvider&&n.etherscan!=="-")try{i.push(new t.EtherscanProvider(a,n.etherscan))}catch{}if(t.AlchemyProvider&&n.alchemy!=="-")try{i.push(new t.AlchemyProvider(a,n.alchemy))}catch{}if(t.PocketProvider&&n.pocket!=="-"){let r=["goerli","ropsten","rinkeby","sepolia"];try{let s=new t.PocketProvider(a,n.pocket);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}}if(t.CloudflareProvider&&n.cloudflare!=="-")try{i.push(new t.CloudflareProvider(a))}catch{}if(t.AnkrProvider&&n.ankr!=="-")try{let r=["ropsten"],s=new t.AnkrProvider(a,n.ankr);s.network&&r.indexOf(s.network.name)===-1&&i.push(s)}catch{}if(i.length===0)return null;if(t.FallbackProvider){let r=1;return n.quorum!=null?r=n.quorum:a==="homestead"&&(r=2),new t.FallbackProvider(i,r)}return i[0]};return e.renetwork=function(t){return va(t)},e}function Jo(a,e){let t=function(n,i){return n.JsonRpcProvider?new n.JsonRpcProvider(a,e):null};return t.renetwork=function(n){return Jo(a,n)},t}var qc={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:va("homestead")},zc={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:va("ropsten")},Gc={chainId:63,name:"classicMordor",_defaultProvider:Jo("https://www.ethercluster.com/mordor","classicMordor")},Ko={unspecified:{chainId:0,name:"unspecified"},homestead:qc,mainnet:qc,morden:{chainId:2,name:"morden"},ropsten:zc,testnet:zc,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:va("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:va("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:va("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:va("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Jo("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Gc,classicTestnet:Gc,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Jo("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:va("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:va("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function cs(a){if(a==null)return null;if(typeof a=="number"){for(let n in Ko){let i=Ko[n];if(i.chainId===a)return{name:i.name,chainId:i.chainId,ensAddress:i.ensAddress||null,_defaultProvider:i._defaultProvider||null}}return{chainId:a,name:"unknown"}}if(typeof a=="string"){let n=Ko[a];return n==null?null:{name:n.name,chainId:n.chainId,ensAddress:n.ensAddress,_defaultProvider:n._defaultProvider||null}}let e=Ko[a.name];if(!e)return typeof a.chainId!="number"&&Hc.throwArgumentError("invalid network chainId","network",a),a;a.chainId!==0&&a.chainId!==e.chainId&&Hc.throwArgumentError("network chainId mismatch","network",a);let t=a._defaultProvider||null;return t==null&&e._defaultProvider&&(hx(e._defaultProvider)?t=e._defaultProvider.renetwork(a):t=e._defaultProvider),{name:a.name,chainId:e.chainId,ensAddress:a.ensAddress||e.ensAddress||null,_defaultProvider:t}}var Wc="web/5.7.1";var xx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})};function Kc(a,e){return xx(this,void 0,void 0,function*(){e==null&&(e={});let t={method:e.method||"GET",headers:e.headers||{},body:e.body||void 0};if(e.skipFetchSetup!==!0&&(t.mode="cors",t.cache="no-cache",t.credentials="same-origin",t.redirect="follow",t.referrer="client"),e.fetchOptions!=null){let s=e.fetchOptions;s.mode&&(t.mode=s.mode),s.cache&&(t.cache=s.cache),s.credentials&&(t.credentials=s.credentials),s.redirect&&(t.redirect=s.redirect),s.referrer&&(t.referrer=s.referrer)}let n=yield fetch(a,t),i=yield n.arrayBuffer(),r={};return n.headers.forEach?n.headers.forEach((s,o)=>{r[o.toLowerCase()]=s}):n.headers.keys().forEach(s=>{r[s.toLowerCase()]=n.headers.get(s)}),{headers:r,statusCode:n.status,statusMessage:n.statusText,body:j(new Uint8Array(i))}})}var bx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Dn=new E(Wc);function Jc(a){return new Promise(e=>{setTimeout(e,a)})}function Ua(a,e){if(a==null)return null;if(typeof a=="string")return a;if(oa(a)){if(e&&(e.split("/")[0]==="text"||e.split(";")[0].trim()==="application/json"))try{return Yt(a)}catch{}return W(a)}return a}function gx(a){return ve(a.replace(/%([0-9a-f][0-9a-f])/gi,(e,t)=>String.fromCharCode(parseInt(t,16))))}function _l(a,e,t){let n=typeof a=="object"&&a.throttleLimit!=null?a.throttleLimit:12;Dn.assertArgument(n>0&&n%1===0,"invalid connection throttle limit","connection.throttleLimit",n);let i=typeof a=="object"?a.throttleCallback:null,r=typeof a=="object"&&typeof a.throttleSlotInterval=="number"?a.throttleSlotInterval:100;Dn.assertArgument(r>0&&r%1===0,"invalid connection throttle slot interval","connection.throttleSlotInterval",r);let s=typeof a=="object"?!!a.errorPassThrough:!1,o={},l=null,p={method:"GET"},c=!1,x=2*60*1e3;if(typeof a=="string")l=a;else if(typeof a=="object"){if((a==null||a.url==null)&&Dn.throwArgumentError("missing URL","connection.url",a),l=a.url,typeof a.timeout=="number"&&a.timeout>0&&(x=a.timeout),a.headers)for(let O in a.headers)o[O.toLowerCase()]={key:O,value:String(a.headers[O])},["if-none-match","if-modified-since"].indexOf(O.toLowerCase())>=0&&(c=!0);if(p.allowGzip=!!a.allowGzip,a.user!=null&&a.password!=null){l.substring(0,6)!=="https:"&&a.allowInsecureAuthentication!==!0&&Dn.throwError("basic authentication requires a secure https url",E.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:a.user,password:"[REDACTED]"});let O=a.user+":"+a.password;o.authorization={key:"Authorization",value:"Basic "+ir(ve(O))}}a.skipFetchSetup!=null&&(p.skipFetchSetup=!!a.skipFetchSetup),a.fetchOptions!=null&&(p.fetchOptions=_e(a.fetchOptions))}let C=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),_=l?l.match(C):null;if(_)try{let O={statusCode:200,statusMessage:"OK",headers:{"content-type":_[1]||"text/plain"},body:_[2]?ar(_[3]):gx(_[3])},U=O.body;return t&&(U=t(O.body,O)),Promise.resolve(U)}catch(O){Dn.throwError("processing response error",E.errors.SERVER_ERROR,{body:Ua(_[1],_[2]),error:O,requestBody:null,requestMethod:"GET",url:l})}e&&(p.method="POST",p.body=e,o["content-type"]==null&&(o["content-type"]={key:"Content-Type",value:"application/octet-stream"}),o["content-length"]==null&&(o["content-length"]={key:"Content-Length",value:String(e.length)}));let v={};Object.keys(o).forEach(O=>{let U=o[O];v[U.key]=U.value}),p.headers=v;let S=function(){let O=null;return{promise:new Promise(function(M,J){x&&(O=setTimeout(()=>{O!=null&&(O=null,J(Dn.makeError("timeout",E.errors.TIMEOUT,{requestBody:Ua(p.body,v["content-type"]),requestMethod:p.method,timeout:x,url:l})))},x))}),cancel:function(){O!=null&&(clearTimeout(O),O=null)}}}(),L=function(){return bx(this,void 0,void 0,function*(){for(let O=0;O=300)&&(S.cancel(),Dn.throwError("bad response",E.errors.SERVER_ERROR,{status:U.statusCode,headers:U.headers,body:Ua(H,U.headers?U.headers["content-type"]:null),requestBody:Ua(p.body,v["content-type"]),requestMethod:p.method,url:l})),t)try{let M=yield t(H,U);return S.cancel(),M}catch(M){if(M.throttleRetry&&O{let o=null;if(r!=null)try{o=JSON.parse(Yt(r))}catch(l){Dn.throwError("invalid JSON",E.errors.SERVER_ERROR,{body:r,error:l})}return t&&(o=t(o,s)),o},i=null;if(e!=null){i=ve(e);let r=typeof a=="string"?{url:a}:_e(a);r.headers?Object.keys(r.headers).filter(o=>o.toLowerCase()==="content-type").length!==0||(r.headers=_e(r.headers),r.headers["content-type"]="application/json"):r.headers={"content-type":"application/json"},a=r}return _l(a,i,n)}function Bn(a,e){return e||(e={}),e=_e(e),e.floor==null&&(e.floor=0),e.ceiling==null&&(e.ceiling=1e4),e.interval==null&&(e.interval=250),new Promise(function(t,n){let i=null,r=!1,s=()=>r?!1:(r=!0,i&&clearTimeout(i),!0);e.timeout&&(i=setTimeout(()=>{s()&&n(new Error("timeout"))},e.timeout));let o=e.retryLimit,l=0;function p(){return a().then(function(c){if(c!==void 0)s()&&t(c);else if(e.oncePoll)e.oncePoll.once("poll",p);else if(e.onceBlock)e.onceBlock.once("block",p);else if(!r){if(l++,l>o){s()&&n(new Error("retry limit reached"));return}let x=e.interval*parseInt(String(Math.random()*Math.pow(2,l)));xe.ceiling&&(x=e.ceiling),setTimeout(p,x)}return null},function(c){s()&&n(c)})}p()})}var Cl=Mn(Xc());var Ae="providers/5.7.2";var ms=new E(Ae),X=class{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let e={},t=this.address.bind(this),n=this.bigNumber.bind(this),i=this.blockTag.bind(this),r=this.data.bind(this),s=this.hash.bind(this),o=this.hex.bind(this),l=this.number.bind(this),p=this.type.bind(this),c=x=>this.data(x,!0);return e.transaction={hash:s,type:p,accessList:X.allowNull(this.accessList.bind(this),null),blockHash:X.allowNull(s,null),blockNumber:X.allowNull(l,null),transactionIndex:X.allowNull(l,null),confirmations:X.allowNull(l,null),from:t,gasPrice:X.allowNull(n),maxPriorityFeePerGas:X.allowNull(n),maxFeePerGas:X.allowNull(n),gasLimit:n,to:X.allowNull(t,null),value:n,nonce:l,data:r,r:X.allowNull(this.uint256),s:X.allowNull(this.uint256),v:X.allowNull(l),creates:X.allowNull(t,null),raw:X.allowNull(r)},e.transactionRequest={from:X.allowNull(t),nonce:X.allowNull(l),gasLimit:X.allowNull(n),gasPrice:X.allowNull(n),maxPriorityFeePerGas:X.allowNull(n),maxFeePerGas:X.allowNull(n),to:X.allowNull(t),value:X.allowNull(n),data:X.allowNull(c),type:X.allowNull(l),accessList:X.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:l,blockNumber:l,transactionHash:s,address:t,topics:X.arrayOf(s),data:r,logIndex:l,blockHash:s},e.receipt={to:X.allowNull(this.address,null),from:X.allowNull(this.address,null),contractAddress:X.allowNull(t,null),transactionIndex:l,root:X.allowNull(o),gasUsed:n,logsBloom:X.allowNull(r),blockHash:s,transactionHash:s,logs:X.arrayOf(this.receiptLog.bind(this)),blockNumber:l,confirmations:X.allowNull(l,null),cumulativeGasUsed:n,effectiveGasPrice:X.allowNull(n),status:X.allowNull(l),type:p},e.block={hash:X.allowNull(s),parentHash:s,number:l,timestamp:l,nonce:X.allowNull(o),difficulty:this.difficulty.bind(this),gasLimit:n,gasUsed:n,miner:X.allowNull(t),extraData:r,transactions:X.allowNull(X.arrayOf(s)),baseFeePerGas:X.allowNull(n)},e.blockWithTransactions=_e(e.block),e.blockWithTransactions.transactions=X.allowNull(X.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:X.allowNull(i,void 0),toBlock:X.allowNull(i,void 0),blockHash:X.allowNull(s,void 0),address:X.allowNull(t,void 0),topics:X.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:X.allowNull(l),blockHash:X.allowNull(s),transactionIndex:l,removed:X.allowNull(this.boolean.bind(this)),address:t,data:X.allowFalsish(r,"0x"),topics:X.arrayOf(s),transactionHash:s,logIndex:l},e}accessList(e){return dn(e||[])}number(e){return e==="0x"?0:F.from(e).toNumber()}type(e){return e==="0x"||e==null?0:F.from(e).toNumber()}bigNumber(e){return F.from(e)}boolean(e){if(typeof e=="boolean")return e;if(typeof e=="string"){if(e=e.toLowerCase(),e==="true")return!0;if(e==="false")return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return typeof e=="string"&&(!t&&e.substring(0,2)!=="0x"&&(e="0x"+e),ie(e))?e.toLowerCase():ms.throwArgumentError("invalid hash","value",e)}data(e,t){let n=this.hex(e,t);if(n.length%2!==0)throw new Error("invalid data; odd-length - "+e);return n}address(e){return fe(e)}callAddress(e){if(!ie(e,32))return null;let t=fe(Ce(e,12));return t===co?null:t}contractAddress(e){return ci(e)}blockTag(e){if(e==null)return"latest";if(e==="earliest")return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if(typeof e=="number"||ie(e))return Hn(e);throw new Error("invalid blockTag")}hash(e,t){let n=this.hex(e,t);return Ft(n)!==32?ms.throwArgumentError("invalid hash","value",e):n}difficulty(e){if(e==null)return null;let t=F.from(e);try{return t.toNumber()}catch{}return null}uint256(e){if(!ie(e))throw new Error("invalid uint256");return me(e,32)}_block(e,t){e.author!=null&&e.miner==null&&(e.miner=e.author);let n=e._difficulty!=null?e._difficulty:e.difficulty,i=X.check(t,e);return i._difficulty=n==null?null:F.from(n),i}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return X.check(this.formats.transactionRequest,e)}transactionResponse(e){e.gas!=null&&e.gasLimit==null&&(e.gasLimit=e.gas),e.to&&F.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),e.input!=null&&e.data==null&&(e.data=e.input),e.to==null&&e.creates==null&&(e.creates=this.contractAddress(e)),(e.type===1||e.type===2)&&e.accessList==null&&(e.accessList=[]);let t=X.check(this.formats.transaction,e);if(e.chainId!=null){let n=e.chainId;ie(n)&&(n=F.from(n).toNumber()),t.chainId=n}else{let n=e.networkId;n==null&&t.v==null&&(n=e.chainId),ie(n)&&(n=F.from(n).toNumber()),typeof n!="number"&&t.v!=null&&(n=(t.v-35)/2,n<0&&(n=0),n=parseInt(n)),typeof n!="number"&&(n=0),t.chainId=n}return t.blockHash&&t.blockHash.replace(/0/g,"")==="x"&&(t.blockHash=null),t}transaction(e){return Oo(e)}receiptLog(e){return X.check(this.formats.receiptLog,e)}receipt(e){let t=X.check(this.formats.receipt,e);if(t.root!=null)if(t.root.length<=4){let n=F.from(t.root).toNumber();n===0||n===1?(t.status!=null&&t.status!==n&&ms.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=n,delete t.root):ms.throwArgumentError("invalid alt-root-status","value.root",t.root)}else t.root.length!==66&&ms.throwArgumentError("invalid root hash","value.root",t.root);return t.status!=null&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map(t=>this.topics(t)):e!=null?this.hash(e,!0):null}filter(e){return X.check(this.formats.filter,e)}filterLog(e){return X.check(this.formats.filterLog,e)}static check(e,t){let n={};for(let i in e)try{let r=e[i](t[i]);r!==void 0&&(n[i]=r)}catch(r){throw r.checkKey=i,r.checkValue=t[i],r}return n}static allowNull(e,t){return function(n){return n==null?t:e(n)}}static allowFalsish(e,t){return function(n){return n?e(n):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");let n=[];return t.forEach(function(i){n.push(e(i))}),n}}};function Al(a){return a&&typeof a.isCommunityResource=="function"}function hs(a){return Al(a)&&a.isCommunityResource()}var Zc=!1;function na(){Zc||(Zc=!0,console.log("========= NOTICE ========="),console.log("Request-Rate Exceeded (this message will not be repeated)"),console.log(""),console.log("The default API keys for each service are provided as a highly-throttled,"),console.log("community resource for low-traffic projects and early prototyping."),console.log(""),console.log("While your application will continue to function, we highly recommended"),console.log("signing up for your own API keys to improve performance, increase your"),console.log("request rate/limit and enable other perks, such as metrics and advanced APIs."),console.log(""),console.log("For more details: https://docs.ethers.io/api-keys/"),console.log("=========================="))}var ue=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},he=new E(Ae),Mx=10;function ef(a){return a==null?"null":(Ft(a)!==32&&he.throwArgumentError("invalid topic","topic",a),a.toLowerCase())}function tf(a){for(a=a.slice();a.length>0&&a[a.length-1]==null;)a.pop();return a.map(e=>{if(Array.isArray(e)){let t={};e.forEach(i=>{t[ef(i)]=!0});let n=Object.keys(t);return n.sort(),n.join("|")}else return ef(e)}).join("&")}function Ix(a){return a===""?[]:a.split(/&/g).map(e=>{if(e==="")return[];let t=e.split("|").map(n=>n==="null"?null:n);return t.length===1?t[0]:t})}function kr(a){if(typeof a=="string"){if(a=a.toLowerCase(),Ft(a)===32)return"tx:"+a;if(a.indexOf(":")===-1)return a}else{if(Array.isArray(a))return"filter:*:"+tf(a);if(ko.isForkEvent(a))throw he.warn("not implemented"),new Error("not implemented");if(a&&typeof a=="object")return"filter:"+(a.address||"*")+":"+tf(a.topics||[])}throw new Error("invalid event - "+a)}function xs(){return new Date().getTime()}function nf(a){return new Promise(e=>{setTimeout(e,a)})}var Cx=["block","network","pending","poll"],Sl=class{constructor(e,t,n){B(this,"tag",e),B(this,"listener",t),B(this,"once",n),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let e=this.tag.split(":");return e[0]!=="tx"?null:e[1]}get filter(){let e=this.tag.split(":");if(e[0]!=="filter")return null;let t=e[1],n=Ix(e[2]),i={};return n.length>0&&(i.topics=n),t&&t!=="*"&&(i.address=t),i}pollable(){return this.tag.indexOf(":")>=0||Cx.indexOf(this.tag)>=0}},Sx={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function El(a){return me(F.from(a).toHexString(),32)}function af(a){return ha.encode(ye([a,Ce(en(en(a)),0,4)]))}var of=new RegExp("^(ipfs)://(.*)$","i"),rf=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),of,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Xo(a,e){try{return Yt(bs(a,e))}catch{}return null}function bs(a,e){if(a==="0x")return null;let t=F.from(Ce(a,e,e+32)).toNumber(),n=F.from(Ce(a,t,t+32)).toNumber();return Ce(a,t+32,t+32+n)}function Ml(a){return a.match(/^ipfs:\/\/ipfs\//i)?a=a.substring(12):a.match(/^ipfs:\/\//i)?a=a.substring(7):he.throwArgumentError("unsupported IPFS format","link",a),`https://gateway.ipfs.io/ipfs/${a}`}function sf(a){let e=j(a);if(e.length>32)throw new Error("internal; should not happen");let t=new Uint8Array(32);return t.set(e,32-e.length),t}function Rx(a){if(a.length%32===0)return a;let e=new Uint8Array(Math.ceil(a.length/32)*32);return e.set(a),e}function uf(a){let e=[],t=0;for(let n=0;nF.from(e).eq(1)).catch(e=>{if(e.code===E.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e})),this._supportsEip2544}_fetch(e,t){return ue(this,void 0,void 0,function*(){let n={to:this.address,ccipReadEnabled:!0,data:At([e,Na(this.name),t||"0x"])},i=!1;(yield this.supportsWildcard())&&(i=!0,n.data=At(["0x9061b923",uf([ns(this.name),n.data])]));try{let r=yield this.provider.call(n);return j(r).length%32===4&&he.throwError("resolver threw error",E.errors.CALL_EXCEPTION,{transaction:n,data:r}),i&&(r=bs(r,0)),r}catch(r){if(r.code===E.errors.CALL_EXCEPTION)return null;throw r}})}_fetchBytes(e,t){return ue(this,void 0,void 0,function*(){let n=yield this._fetch(e,t);return n!=null?bs(n,0):null})}_getAddress(e,t){let n=Sx[String(e)];if(n==null&&he.throwError(`unsupported coin type: ${e}`,E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),n.ilk==="eth")return this.provider.formatter.address(t);let i=j(t);if(n.p2pkh!=null){let r=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return af(ye([[n.p2pkh],"0x"+r[2]]))}}if(n.p2sh!=null){let r=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(r){let s=parseInt(r[1],16);if(r[2].length===s*2&&s>=1&&s<=75)return af(ye([[n.p2sh],"0x"+r[2]]))}}if(n.prefix!=null){let r=i[1],s=i[0];if(s===0?r!==20&&r!==32&&(s=-1):s=-1,s>=0&&i.length===2+r&&r>=1&&r<=75){let o=Cl.default.toWords(i.slice(2));return o.unshift(s),Cl.default.encode(n.prefix,o)}}return null}getAddress(e){return ue(this,void 0,void 0,function*(){if(e==null&&(e=60),e===60)try{let i=yield this._fetch("0x3b3b57de");return i==="0x"||i===tr?null:this.provider.formatter.callAddress(i)}catch(i){if(i.code===E.errors.CALL_EXCEPTION)return null;throw i}let t=yield this._fetchBytes("0xf1cb7e06",El(e));if(t==null||t==="0x")return null;let n=this._getAddress(e,t);return n==null&&he.throwError("invalid or unsupported coin data",E.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),n})}getAvatar(){return ue(this,void 0,void 0,function*(){let e=[{type:"name",content:this.name}];try{let t=yield this.getText("avatar");if(t==null)return null;for(let n=0;ns[l]);return"sia://"+o}return he.throwError("invalid or unsupported content hash data",E.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})})}getText(e){return ue(this,void 0,void 0,function*(){let t=ve(e);t=ye([El(64),El(t.length),t]),t.length%32!==0&&(t=ye([t,me("0x",32-e.length%32)]));let n=yield this._fetchBytes("0x59d1d43c",W(t));return n==null||n==="0x"?null:Yt(n)})}},Il=null,Px=1,aa=class extends Xt{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),B(this,"anyNetwork",e==="any"),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch(t=>{}),this._ready().catch(t=>{});else{let t=ht(new.target,"getNetwork")(e);t?(B(this,"_network",t),this.emit("network",t,null)):he.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return ue(this,void 0,void 0,function*(){if(this._network==null){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch{}e==null&&(e=yield this.detectNetwork()),e||he.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(this.anyNetwork?this._network=e:B(this,"_network",e),this.emit("network",e,null))}return this._network})}get ready(){return Bn(()=>this._ready().then(e=>e,e=>{if(!(e.code===E.errors.NETWORK_ERROR&&e.event==="noNetwork"))throw e}))}static getFormatter(){return Il==null&&(Il=new X),Il}static getNetwork(e){return cs(e??"homestead")}ccipReadFetch(e,t,n){return ue(this,void 0,void 0,function*(){if(this.disableCcipRead||n.length===0)return null;let i=e.to.toLowerCase(),r=t.toLowerCase(),s=[];for(let o=0;o=0?null:JSON.stringify({data:r,sender:i}),x=yield On({url:p,errorPassThrough:!0},c,(_,v)=>(_.status=v.statusCode,_));if(x.data)return x.data;let C=x.message||"unknown error";if(x.status>=400&&x.status<500)return he.throwError(`response not found during CCIP fetch: ${C}`,E.errors.SERVER_ERROR,{url:l,errorMessage:C});s.push(C)}return he.throwError(`error encountered during CCIP fetch: ${s.map(o=>JSON.stringify(o)).join(", ")}`,E.errors.SERVER_ERROR,{urls:n,errorMessages:s})})}_getInternalBlockNumber(e){return ue(this,void 0,void 0,function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){let i=this._internalBlockNumber;try{let r=yield i;if(xs()-r.respTime<=e)return r.blockNumber;break}catch{if(this._internalBlockNumber===i)break}}let t=xs(),n=Se({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(i=>null,i=>i)}).then(({blockNumber:i,networkError:r})=>{if(r)throw this._internalBlockNumber===n&&(this._internalBlockNumber=null),r;let s=xs();return i=F.from(i).toNumber(),i{this._internalBlockNumber===n&&(this._internalBlockNumber=null)}),(yield n).blockNumber})}poll(){return ue(this,void 0,void 0,function*(){let e=Px++,t=[],n=null;try{n=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(i){this.emit("error",i);return}if(this._setFastBlockNumber(n),this.emit("poll",e,n),n===this._lastBlockNumber){this.emit("didPoll",e);return}if(this._emitted.block===-2&&(this._emitted.block=n-1),Math.abs(this._emitted.block-n)>1e3)he.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${n})`),this.emit("error",he.makeError("network block skew detected",E.errors.NETWORK_ERROR,{blockNumber:n,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",n);else for(let i=this._emitted.block+1;i<=n;i++)this.emit("block",i);this._emitted.block!==n&&(this._emitted.block=n,Object.keys(this._emitted).forEach(i=>{if(i==="block")return;let r=this._emitted[i];r!=="pending"&&n-r>12&&delete this._emitted[i]})),this._lastBlockNumber===-2&&(this._lastBlockNumber=n-1),this._events.forEach(i=>{switch(i.type){case"tx":{let r=i.hash,s=this.getTransactionReceipt(r).then(o=>(!o||o.blockNumber==null||(this._emitted["t:"+r]=o.blockNumber,this.emit(r,o)),null)).catch(o=>{this.emit("error",o)});t.push(s);break}case"filter":{if(!i._inflight){i._inflight=!0,i._lastBlockNumber===-2&&(i._lastBlockNumber=n-1);let r=i.filter;r.fromBlock=i._lastBlockNumber+1,r.toBlock=n;let s=r.toBlock-this._maxFilterBlockRange;s>r.fromBlock&&(r.fromBlock=s),r.fromBlock<0&&(r.fromBlock=0);let o=this.getLogs(r).then(l=>{i._inflight=!1,l.length!==0&&l.forEach(p=>{p.blockNumber>i._lastBlockNumber&&(i._lastBlockNumber=p.blockNumber),this._emitted["b:"+p.blockHash]=p.blockNumber,this._emitted["t:"+p.transactionHash]=p.blockNumber,this.emit(r,p)})}).catch(l=>{this.emit("error",l),i._inflight=!1});t.push(o)}break}}}),this._lastBlockNumber=n,Promise.all(t).then(()=>{this.emit("didPoll",e)}).catch(i=>{this.emit("error",i)})})}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return ue(this,void 0,void 0,function*(){return he.throwError("provider does not support network detection",E.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return ue(this,void 0,void 0,function*(){let e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield nf(0),this._network;let n=he.makeError("underlying network changed",E.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",n),n}return e})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(e=>{this._setFastBlockNumber(e)},e=>{}),this._fastBlockNumber!=null?this._fastBlockNumber:-1}get polling(){return this._poller!=null}set polling(e){e&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if(typeof e!="number"||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let e=xs();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then(t=>((this._fastBlockNumber==null||t>this._fastBlockNumber)&&(this._fastBlockNumber=t),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(e){this._fastBlockNumber!=null&&ethis._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,n){return ue(this,void 0,void 0,function*(){return this._waitForTransaction(e,t??1,n||0,null)})}_waitForTransaction(e,t,n,i){return ue(this,void 0,void 0,function*(){let r=yield this.getTransactionReceipt(e);return(r?r.confirmations:0)>=t?r:new Promise((s,o)=>{let l=[],p=!1,c=function(){return p?!0:(p=!0,l.forEach(C=>{C()}),!1)},x=C=>{C.confirmations{this.removeListener(e,x)}),i){let C=i.startBlock,_=null,v=S=>ue(this,void 0,void 0,function*(){p||(yield nf(1e3),this.getTransactionCount(i.from).then(L=>ue(this,void 0,void 0,function*(){if(!p){if(L<=i.nonce)C=S;else{{let O=yield this.getTransaction(e);if(O&&O.blockNumber!=null)return}for(_==null&&(_=C-3,_{p||this.once("block",v)}))});if(p)return;this.once("block",v),l.push(()=>{this.removeListener("block",v)})}if(typeof n=="number"&&n>0){let C=setTimeout(()=>{c()||o(he.makeError("timeout exceeded",E.errors.TIMEOUT,{timeout:n}))},n);C.unref&&C.unref(),l.push(()=>{clearTimeout(C)})}})})}getBlockNumber(){return ue(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let e=yield this.perform("getGasPrice",{});try{return F.from(e)}catch(t){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}})}getBalance(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Se({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getBalance",n);try{return F.from(i)}catch(r){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getBalance",params:n,result:i,error:r})}})}getTransactionCount(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Se({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getTransactionCount",n);try{return F.from(i).toNumber()}catch(r){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getTransactionCount",params:n,result:i,error:r})}})}getCode(e,t){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let n=yield Se({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),i=yield this.perform("getCode",n);try{return W(i)}catch(r){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getCode",params:n,result:i,error:r})}})}getStorageAt(e,t,n){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let i=yield Se({address:this._getAddress(e),blockTag:this._getBlockTag(n),position:Promise.resolve(t).then(s=>Hn(s))}),r=yield this.perform("getStorageAt",i);try{return W(r)}catch(s){return he.throwError("bad result from backend",E.errors.SERVER_ERROR,{method:"getStorageAt",params:i,result:r,error:s})}})}_wrapTransaction(e,t,n){if(t!=null&&Ft(t)!==32)throw new Error("invalid response - sendTransaction");let i=e;return t!=null&&e.hash!==t&&he.throwError("Transaction hash mismatch from Provider.sendTransaction.",E.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),i.wait=(r,s)=>ue(this,void 0,void 0,function*(){r==null&&(r=1),s==null&&(s=0);let o;r!==0&&n!=null&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:n});let l=yield this._waitForTransaction(e.hash,r,s,o);return l==null&&r===0?null:(this._emitted["t:"+e.hash]=l.blockNumber,l.status===0&&he.throwError("transaction failed",E.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:l}),l)}),i}sendTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Promise.resolve(e).then(r=>W(r)),n=this.formatter.transaction(e);n.confirmations==null&&(n.confirmations=0);let i=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let r=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(n,r,i)}catch(r){throw r.transaction=n,r.transactionHash=n.hash,r}})}_getTransactionRequest(e){return ue(this,void 0,void 0,function*(){let t=yield e,n={};return["from","to"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?this._getAddress(r):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?F.from(r):null))}),["type"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r??null))}),t.accessList&&(n.accessList=this.formatter.accessList(t.accessList)),["data"].forEach(i=>{t[i]!=null&&(n[i]=Promise.resolve(t[i]).then(r=>r?W(r):null))}),this.formatter.transactionRequest(yield Se(n))})}_getFilter(e){return ue(this,void 0,void 0,function*(){e=yield e;let t={};return e.address!=null&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach(n=>{e[n]!=null&&(t[n]=e[n])}),["fromBlock","toBlock"].forEach(n=>{e[n]!=null&&(t[n]=this._getBlockTag(e[n]))}),this.formatter.filter(yield Se(t))})}_call(e,t,n){return ue(this,void 0,void 0,function*(){n>=Mx&&he.throwError("CCIP read exceeded maximum redirections",E.errors.SERVER_ERROR,{redirects:n,transaction:e});let i=e.to,r=yield this.perform("call",{transaction:e,blockTag:t});if(n>=0&&t==="latest"&&i!=null&&r.substring(0,10)==="0x556f1830"&&Ft(r)%32===4)try{let s=Ce(r,4),o=Ce(s,0,32);F.from(o).eq(i)||he.throwError("CCIP Read sender did not match",E.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:r});let l=[],p=F.from(Ce(s,32,64)).toNumber(),c=F.from(Ce(s,p,p+32)).toNumber(),x=Ce(s,p+32);for(let O=0;Oue(this,void 0,void 0,function*(){let r=yield this.perform("getBlock",i);if(r==null)return i.blockHash!=null&&this._emitted["b:"+i.blockHash]==null||i.blockTag!=null&&n>this._emitted.block?null:void 0;if(t){let s=null;for(let l=0;lthis._wrapTransaction(l)),o}return this.formatter.block(r)}),{oncePoll:this})})}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Bn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransaction",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;let i=this.formatter.transactionResponse(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return this._wrapTransaction(i)}),{oncePoll:this})})}getTransactionReceipt(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork(),e=yield e;let t={transactionHash:this.formatter.hash(e,!0)};return Bn(()=>ue(this,void 0,void 0,function*(){let n=yield this.perform("getTransactionReceipt",t);if(n==null)return this._emitted["t:"+e]==null?null:void 0;if(n.blockHash==null)return;let i=this.formatter.receipt(n);if(i.blockNumber==null)i.confirmations=0;else if(i.confirmations==null){let s=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-i.blockNumber+1;s<=0&&(s=1),i.confirmations=s}return i}),{oncePoll:this})})}getLogs(e){return ue(this,void 0,void 0,function*(){yield this.getNetwork();let t=yield Se({filter:this._getFilter(e)}),n=yield this.perform("getLogs",t);return n.forEach(i=>{i.removed==null&&(i.removed=!1)}),X.arrayOf(this.formatter.filterLog.bind(this.formatter))(n)})}getEtherPrice(){return ue(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(e){return ue(this,void 0,void 0,function*(){if(e=yield e,typeof e=="number"&&e<0){e%1&&he.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)})}getResolver(e){return ue(this,void 0,void 0,function*(){let t=e;for(;;){if(t===""||t==="."||e!=="eth"&&t==="eth")return null;let n=yield this._getResolver(t,"getResolver");if(n!=null){let i=new Ar(this,n,e);return t!==e&&!(yield i.supportsWildcard())?null:i}t=t.split(".").slice(1).join(".")}})}_getResolver(e,t){return ue(this,void 0,void 0,function*(){t==null&&(t="ENS");let n=yield this.getNetwork();n.ensAddress||he.throwError("network does not support ENS",E.errors.UNSUPPORTED_OPERATION,{operation:t,network:n.name});try{let i=yield this.call({to:n.ensAddress,data:"0x0178b8bf"+Na(e).substring(2)});return this.formatter.callAddress(i)}catch{}return null})}resolveName(e){return ue(this,void 0,void 0,function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(n){if(ie(e))throw n}typeof e!="string"&&he.throwArgumentError("invalid ENS name","name",e);let t=yield this.getResolver(e);return t?yield t.getAddress():null})}lookupAddress(e){return ue(this,void 0,void 0,function*(){e=yield e,e=this.formatter.address(e);let t=e.substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(t,"lookupAddress");if(n==null)return null;let i=Xo(yield this.call({to:n,data:"0x691f3431"+Na(t).substring(2)}),0);return(yield this.resolveName(i))!=e?null:i})}getAvatar(e){return ue(this,void 0,void 0,function*(){let t=null;if(ie(e)){let r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",s=yield this._getResolver(r,"getAvatar");if(!s)return null;t=new Ar(this,s,r);try{let o=yield t.getAvatar();if(o)return o.url}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o}try{let o=Xo(yield this.call({to:s,data:"0x691f3431"+Na(r).substring(2)}),0);t=yield this.getResolver(o)}catch(o){if(o.code!==E.errors.CALL_EXCEPTION)throw o;return null}}else if(t=yield this.getResolver(e),!t)return null;let n=yield t.getAvatar();return n==null?null:n.url})}perform(e,t){return he.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_stopEvent(e){this.polling=this._events.filter(t=>t.pollable()).length>0}_addEventListener(e,t,n){let i=new Sl(kr(e),t,n);return this._events.push(i),this._startEvent(i),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let n=!1,i=[],r=kr(e);return this._events=this._events.filter(s=>s.tag!==r?!0:(setTimeout(()=>{s.listener.apply(this,t)},0),n=!0,s.once?(i.push(s),!1):!0)),i.forEach(s=>{this._stopEvent(s)}),n}listenerCount(e){if(!e)return this._events.length;let t=kr(e);return this._events.filter(n=>n.tag===t).length}listeners(e){if(e==null)return this._events.map(n=>n.listener);let t=kr(e);return this._events.filter(n=>n.tag===t).map(n=>n.listener)}off(e,t){if(t==null)return this.removeAllListeners(e);let n=[],i=!1,r=kr(e);return this._events=this._events.filter(s=>s.tag!==r||s.listener!=t||i?!0:(i=!0,n.push(s),!1)),n.forEach(s=>{this._stopEvent(s)}),this}removeAllListeners(e){let t=[];if(e==null)t=this._events,this._events=[];else{let n=kr(e);this._events=this._events.filter(i=>i.tag!==n?!0:(t.push(i),!1))}return t.forEach(n=>{this._stopEvent(n)}),this}};var wa=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Mt=new E(Ae),Nx=["call","estimateGas"];function Ts(a,e){if(a==null)return null;if(typeof a.message=="string"&&a.message.match("reverted")){let t=ie(a.data)?a.data:null;if(!e||t)return{message:a.message,data:t}}if(typeof a=="object"){for(let t in a){let n=Ts(a[t],e);if(n)return n}return null}if(typeof a=="string")try{return Ts(JSON.parse(a),e)}catch{}return null}function lf(a,e,t){let n=t.transaction||t.signedTransaction;if(a==="call"){let r=Ts(e,!0);if(r)return r.data;Mt.throwError("missing revert data in call exception; Transaction reverted without a reason string",E.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:e})}if(a==="estimateGas"){let r=Ts(e.body,!1);r==null&&(r=Ts(e,!1)),r&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:a,transaction:n,error:e})}let i=e.message;throw e.code===E.errors.SERVER_ERROR&&e.error&&typeof e.error.message=="string"?i=e.error.message:typeof e.body=="string"?i=e.body:typeof e.responseText=="string"&&(i=e.responseText),i=(i||"").toLowerCase(),i.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Mt.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:n}),i.match(/nonce (is )?too low/i)&&Mt.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:a,transaction:n}),i.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Mt.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:n}),i.match(/only replay-protected/i)&&Mt.throwError("legacy pre-eip-155 transactions not supported",E.errors.UNSUPPORTED_OPERATION,{error:e,method:a,transaction:n}),Nx.indexOf(a)>=0&&i.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Mt.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:n}),e}function df(a){return new Promise(function(e){setTimeout(e,a)})}function Dx(a){if(a.error){let e=new Error(a.error.message);throw e.code=a.error.code,e.data=a.error.data,e}return a.result}function gs(a){return a&&a.toLowerCase()}var Rl={},Er=class extends Pt{constructor(e,t,n){if(super(),e!==Rl)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");B(this,"provider",t),n==null&&(n=0),typeof n=="string"?(B(this,"_address",this.provider.formatter.address(n)),B(this,"_index",null)):typeof n=="number"?(B(this,"_index",n),B(this,"_address",null)):Mt.throwArgumentError("invalid address or index","addressOrIndex",n)}connect(e){return Mt.throwError("cannot alter JSON-RPC Signer connection",E.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new Pl(Rl,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(e=>(e.length<=this._index&&Mt.throwError("unknown account #"+this._index,E.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index])))}sendUncheckedTransaction(e){e=_e(e);let t=this.getAddress().then(n=>(n&&(n=n.toLowerCase()),n));if(e.gasLimit==null){let n=_e(e);n.from=t,e.gasLimit=this.provider.estimateGas(n)}return e.to!=null&&(e.to=Promise.resolve(e.to).then(n=>wa(this,void 0,void 0,function*(){if(n==null)return null;let i=yield this.provider.resolveName(n);return i==null&&Mt.throwArgumentError("provided ENS name resolves to null","tx.to",n),i}))),Se({tx:Se(e),sender:t}).then(({tx:n,sender:i})=>{n.from!=null?n.from.toLowerCase()!==i&&Mt.throwArgumentError("from address mismatch","transaction",e):n.from=i;let r=this.provider.constructor.hexlifyTransaction(n,{from:!0});return this.provider.send("eth_sendTransaction",[r]).then(s=>s,s=>(typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected transaction",E.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:n}),lf("sendTransaction",s,r)))})}signTransaction(e){return Mt.throwError("signing transactions is unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return wa(this,void 0,void 0,function*(){let t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),n=yield this.sendUncheckedTransaction(e);try{return yield Bn(()=>wa(this,void 0,void 0,function*(){let i=yield this.provider.getTransaction(n);if(i!==null)return this.provider._wrapTransaction(i,n,t)}),{oncePoll:this.provider})}catch(i){throw i.transactionHash=n,i}})}signMessage(e){return wa(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("personal_sign",[W(t),n.toLowerCase()])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"signMessage",from:n,messageData:e}),i}})}_legacySignMessage(e){return wa(this,void 0,void 0,function*(){let t=typeof e=="string"?ve(e):e,n=yield this.getAddress();try{return yield this.provider.send("eth_sign",[n.toLowerCase(),W(t)])}catch(i){throw typeof i.message=="string"&&i.message.match(/user denied/i)&&Mt.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:n,messageData:e}),i}})}_signTypedData(e,t,n){return wa(this,void 0,void 0,function*(){let i=yield gt.resolveNames(e,t,n,s=>this.provider.resolveName(s)),r=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[r.toLowerCase(),JSON.stringify(gt.getPayload(i.domain,t,i.value))])}catch(s){throw typeof s.message=="string"&&s.message.match(/user denied/i)&&Mt.throwError("user rejected signing",E.errors.ACTION_REJECTED,{action:"_signTypedData",from:r,messageData:{domain:i.domain,types:t,value:i.value}}),s}})}unlock(e){return wa(this,void 0,void 0,function*(){let t=this.provider,n=yield this.getAddress();return t.send("personal_unlockAccount",[n.toLowerCase(),e,null])})}},Pl=class extends Er{sendTransaction(e){return this.sendUncheckedTransaction(e).then(t=>({hash:t,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:n=>this.provider.waitForTransaction(t,n)}))}},Ox={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0},tn=class extends aa{constructor(e,t){let n=t;n==null&&(n=new Promise((i,r)=>{setTimeout(()=>{this.detectNetwork().then(s=>{i(s)},s=>{r(s)})},0)})),super(n),e||(e=ht(this.constructor,"defaultUrl")()),typeof e=="string"?B(this,"connection",Object.freeze({url:e})):B(this,"connection",Object.freeze(_e(e))),this._nextId=42}get _cache(){return this._eventLoopCache==null&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return wa(this,void 0,void 0,function*(){yield df(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch{try{e=yield this.send("net_version",[])}catch{}}if(e!=null){let t=ht(this.constructor,"getNetwork");try{return t(F.from(e).toNumber())}catch(n){return Mt.throwError("could not detect network",E.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:n})}}return Mt.throwError("could not detect network",E.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(e){return new Er(Rl,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(e=>e.map(t=>this.formatter.address(t)))}send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:mt(n),provider:this});let i=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(i&&this._cache[e])return this._cache[e];let r=On(this.connection,JSON.stringify(n),Dx).then(s=>(this.emit("debug",{action:"response",request:n,response:s,provider:this}),s),s=>{throw this.emit("debug",{action:"response",error:s,request:n,provider:this}),s});return i&&(this._cache[e]=r,setTimeout(()=>{this._cache[e]=null},0)),r}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[gs(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[gs(t.address),t.blockTag]];case"getCode":return["eth_getCode",[gs(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[gs(t.address),me(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":{let n=ht(this.constructor,"hexlifyTransaction");return["eth_call",[n(t.transaction,{from:!0}),t.blockTag]]}case"estimateGas":{let n=ht(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[n(t.transaction,{from:!0})]]}case"getLogs":return t.filter&&t.filter.address!=null&&(t.filter.address=gs(t.filter.address)),["eth_getLogs",[t.filter]];default:break}return null}perform(e,t){return wa(this,void 0,void 0,function*(){if(e==="call"||e==="estimateGas"){let i=t.transaction;if(i&&i.type!=null&&F.from(i.type).isZero()&&i.maxFeePerGas==null&&i.maxPriorityFeePerGas==null){let r=yield this.getFeeData();r.maxFeePerGas==null&&r.maxPriorityFeePerGas==null&&(t=_e(t),t.transaction=_e(i),delete t.transaction.type)}}let n=this.prepareRequest(e,t);n==null&&Mt.throwError(e+" not implemented",E.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(n[0],n[1])}catch(i){return lf(e,i,t)}})}_startEvent(e){e.tag==="pending"&&this._startPending(),super._startEvent(e)}_startPending(){if(this._pendingFilter!=null)return;let e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then(function(n){function i(){e.send("eth_getFilterChanges",[n]).then(function(r){if(e._pendingFilter!=t)return null;let s=Promise.resolve();return r.forEach(function(o){e._emitted["t:"+o.toLowerCase()]="pending",s=s.then(function(){return e.getTransaction(o).then(function(l){return e.emit("pending",l),null})})}),s.then(function(){return df(1e3)})}).then(function(){if(e._pendingFilter!=t){e.send("eth_uninstallFilter",[n]);return}return setTimeout(function(){i()},0),null}).catch(r=>{})}return i(),n}).catch(n=>{})}_stopEvent(e){e.tag==="pending"&&this.listenerCount("pending")===0&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){let n=_e(Ox);if(t)for(let r in t)t[r]&&(n[r]=!0);Qi(e,n);let i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(r){if(e[r]==null)return;let s=Hn(F.from(e[r]));r==="gasLimit"&&(r="gas"),i[r]=s}),["from","to","data"].forEach(function(r){e[r]!=null&&(i[r]=W(e[r]))}),e.accessList&&(i.accessList=dn(e.accessList)),i}};var Mr=null;try{if(Mr=WebSocket,Mr==null)throw new Error("inject please")}catch{let e=new E(Ae);Mr=function(){e.throwError("WebSockets not supported in this environment",E.errors.UNSUPPORTED_OPERATION,{operation:"new WebSocket()"})}}var Nl=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Zo=new E(Ae),Bx=1,_a=class extends tn{constructor(e,t){t==="any"&&Zo.throwError("WebSocketProvider does not support 'any' network yet",E.errors.UNSUPPORTED_OPERATION,{operation:"network:any"}),typeof e=="string"?super(e,t):super("_websocket",t),this._pollingInterval=-1,this._wsReady=!1,typeof e=="string"?B(this,"_websocket",new Mr(this.connection.url)):B(this,"_websocket",e),B(this,"_requests",{}),B(this,"_subs",{}),B(this,"_subIds",{}),B(this,"_detectNetwork",super.detectNetwork()),this.websocket.onopen=()=>{this._wsReady=!0,Object.keys(this._requests).forEach(i=>{this.websocket.send(this._requests[i].payload)})},this.websocket.onmessage=i=>{let r=i.data,s=JSON.parse(r);if(s.id!=null){let o=String(s.id),l=this._requests[o];if(delete this._requests[o],s.result!==void 0)l.callback(null,s.result),this.emit("debug",{action:"response",request:JSON.parse(l.payload),response:s.result,provider:this});else{let p=null;s.error?(p=new Error(s.error.message||"unknown error"),B(p,"code",s.error.code||null),B(p,"response",r)):p=new Error("unknown error"),l.callback(p,void 0),this.emit("debug",{action:"response",error:p,request:JSON.parse(l.payload),provider:this})}}else if(s.method==="eth_subscription"){let o=this._subs[s.params.subscription];o&&o.processFunc(s.params.result)}else console.warn("this should not happen")};let n=setInterval(()=>{this.emit("poll")},1e3);n.unref&&n.unref()}get websocket(){return this._websocket}detectNetwork(){return this._detectNetwork}get pollingInterval(){return 0}resetEventsBlock(e){Zo.throwError("cannot reset events block on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"resetEventBlock"})}set pollingInterval(e){Zo.throwError("cannot set polling interval on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPollingInterval"})}poll(){return Nl(this,void 0,void 0,function*(){return null})}set polling(e){!e||Zo.throwError("cannot set polling on WebSocketProvider",E.errors.UNSUPPORTED_OPERATION,{operation:"setPolling"})}send(e,t){let n=Bx++;return new Promise((i,r)=>{function s(l,p){return l?r(l):i(p)}let o=JSON.stringify({method:e,params:t,id:n,jsonrpc:"2.0"});this.emit("debug",{action:"request",request:JSON.parse(o),provider:this}),this._requests[String(n)]={callback:s,payload:o},this._wsReady&&this.websocket.send(o)})}static defaultUrl(){return"ws://localhost:8546"}_subscribe(e,t,n){return Nl(this,void 0,void 0,function*(){let i=this._subIds[e];i==null&&(i=Promise.all(t).then(s=>this.send("eth_subscribe",s)),this._subIds[e]=i);let r=yield i;this._subs[r]={tag:e,processFunc:n}})}_startEvent(e){switch(e.type){case"block":this._subscribe("block",["newHeads"],t=>{let n=F.from(t.number).toNumber();this._emitted.block=n,this.emit("block",n)});break;case"pending":this._subscribe("pending",["newPendingTransactions"],t=>{this.emit("pending",t)});break;case"filter":this._subscribe(e.tag,["logs",this._getFilter(e.filter)],t=>{t.removed==null&&(t.removed=!1),this.emit(e.filter,this.formatter.filterLog(t))});break;case"tx":{let t=n=>{let i=n.hash;this.getTransactionReceipt(i).then(r=>{!r||this.emit(i,r)})};t(e),this._subscribe("tx",["newHeads"],n=>{this._events.filter(i=>i.type==="tx").forEach(t)});break}case"debug":case"poll":case"willPoll":case"didPoll":case"error":break;default:console.log("unhandled:",e);break}}_stopEvent(e){let t=e.tag;if(e.type==="tx"){if(this._events.filter(i=>i.type==="tx").length)return;t="tx"}else if(this.listenerCount(e.event))return;let n=this._subIds[t];!n||(delete this._subIds[t],n.then(i=>{!this._subs[i]||(delete this._subs[i],this.send("eth_unsubscribe",[i]))}))}destroy(){return Nl(this,void 0,void 0,function*(){this.websocket.readyState===Mr.CONNECTING&&(yield new Promise(e=>{this.websocket.onopen=function(){e(!0)},this.websocket.onerror=function(){e(!1)}})),this.websocket.close(1e3)})}};var Fx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},vs=new E(Ae),ws=class extends tn{detectNetwork(){let e=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return Fx(this,void 0,void 0,function*(){let t=this.network;return t==null&&(t=yield e.detectNetwork.call(this),t||vs.throwError("no network detected",E.errors.UNKNOWN_ERROR,{}),this._network==null&&(B(this,"_network",t),this.emit("network",t,null))),t})}},St=class extends ws{constructor(e,t){vs.checkAbstract(new.target,St),e=ht(new.target,"getNetwork")(e),t=ht(new.target,"getApiKey")(t);let n=ht(new.target,"getUrl")(e,t);super(n,e),typeof t=="string"?B(this,"apiKey",t):t!=null&&Object.keys(t).forEach(i=>{B(this,i,t[i])})}_startPending(){vs.warn("WARNING: API provider does not support pending filters")}isCommunityResource(){return!1}getSigner(e){return vs.throwError("API provider does not support signing",E.errors.UNSUPPORTED_OPERATION,{operation:"getSigner"})}listAccounts(){return Promise.resolve([])}static getApiKey(e){return e}static getUrl(e,t){return vs.throwError("not implemented; sub-classes must override getUrl",E.errors.NOT_IMPLEMENTED,{operation:"getUrl"})}};var pf=new E(Ae),eu="_gg7wSSi0KMBsdKnGVfHDueq6xMB9EkC",_s=class extends _a{constructor(e,t){let n=new Ir(e,t),i=n.connection.url.replace(/^http/i,"ws").replace(".alchemyapi.",".ws.alchemyapi.");super(i,n.network),B(this,"apiKey",n.apiKey)}isCommunityResource(){return this.apiKey===eu}},Ir=class extends St{static getWebSocketProvider(e,t){return new _s(e,t)}static getApiKey(e){return e==null?eu:(e&&typeof e!="string"&&pf.throwArgumentError("invalid apiKey","apiKey",e),e)}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="eth-mainnet.alchemyapi.io/v2/";break;case"goerli":n="eth-goerli.g.alchemy.com/v2/";break;case"matic":n="polygon-mainnet.g.alchemy.com/v2/";break;case"maticmum":n="polygon-mumbai.g.alchemy.com/v2/";break;case"arbitrum":n="arb-mainnet.g.alchemy.com/v2/";break;case"arbitrum-goerli":n="arb-goerli.g.alchemy.com/v2/";break;case"optimism":n="opt-mainnet.g.alchemy.com/v2/";break;case"optimism-goerli":n="opt-goerli.g.alchemy.com/v2/";break;default:pf.throwArgumentError("unsupported network","network",arguments[0])}return{allowGzip:!0,url:"https://"+n+t,throttleCallback:(i,r)=>(t===eu&&na(),Promise.resolve(!0))}}isCommunityResource(){return this.apiKey===eu}};var Lx=new E(Ae),tu="9f7d929b018cdffb338517efa06f58359e86ff1ffd350bc889738523659e7972";function Ux(a){switch(a){case"homestead":return"rpc.ankr.com/eth/";case"ropsten":return"rpc.ankr.com/eth_ropsten/";case"rinkeby":return"rpc.ankr.com/eth_rinkeby/";case"goerli":return"rpc.ankr.com/eth_goerli/";case"matic":return"rpc.ankr.com/polygon/";case"arbitrum":return"rpc.ankr.com/arbitrum/"}return Lx.throwArgumentError("unsupported network","name",a)}var ks=class extends St{isCommunityResource(){return this.apiKey===tu}static getApiKey(e){return e??tu}static getUrl(e,t){t==null&&(t=tu);let n={allowGzip:!0,url:"https://"+Ux(e.name)+t,throttleCallback:(i,r)=>(t.apiKey===tu&&na(),Promise.resolve(!0))};return t.projectSecret!=null&&(n.user="",n.password=t.projectSecret),n}};var Vx=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},yf=new E(Ae),As=class extends St{static getApiKey(e){return e!=null&&yf.throwArgumentError("apiKey not supported for cloudflare","apiKey",e),null}static getUrl(e,t){let n=null;switch(e.name){case"homestead":n="https://cloudflare-eth.com/";break;default:yf.throwArgumentError("unsupported network","network",arguments[0])}return n}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return Vx(this,void 0,void 0,function*(){return e==="getBlockNumber"?(yield n.perform.call(this,"getBlock",{blockTag:"latest"})).number:n.perform.call(this,e,t)})}};var nu=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},Va=new E(Ae);function cf(a){let e={};for(let t in a){if(a[t]==null)continue;let n=a[t];t==="type"&&n===0||({type:!0,gasLimit:!0,gasPrice:!0,maxFeePerGs:!0,maxPriorityFeePerGas:!0,nonce:!0,value:!0}[t]?n=Hn(W(n)):t==="accessList"?n="["+dn(n).map(i=>`{address:"${i.address}",storageKeys:["${i.storageKeys.join('","')}"]}`).join(",")+"]":n=W(n),e[t]=n)}return e}function jx(a){if(a.status==0&&(a.message==="No records found"||a.message==="No transactions found"))return a.result;if(a.status!=1||typeof a.message!="string"||!a.message.match(/^OK/)){let e=new Error("invalid response");throw e.result=JSON.stringify(a),(a.result||"").toLowerCase().indexOf("rate limit")>=0&&(e.throttleRetry=!0),e}return a.result}function ff(a){if(a&&a.status==0&&a.message=="NOTOK"&&(a.result||"").toLowerCase().indexOf("rate limit")>=0){let e=new Error("throttled response");throw e.result=JSON.stringify(a),e.throttleRetry=!0,e}if(a.jsonrpc!="2.0"){let e=new Error("invalid response");throw e.result=JSON.stringify(a),e}if(a.error){let e=new Error(a.error.message||"unknown error");throw a.error.code&&(e.code=a.error.code),a.error.data&&(e.data=a.error.data),e}return a.result}function mf(a){if(a==="pending")throw new Error("pending not supported");return a==="latest"?a:parseInt(a.substring(2),16)}function Dl(a,e,t){if(a==="call"&&e.code===E.errors.SERVER_ERROR){let i=e.error;if(i&&(i.message.match(/reverted/i)||i.message.match(/VM execution error/i))){let r=i.data;if(r&&(r="0x"+r.replace(/^.*0x/i,"")),ie(r))return r;Va.throwError("missing revert data in call exception",E.errors.CALL_EXCEPTION,{error:e,data:"0x"})}}let n=e.message;throw e.code===E.errors.SERVER_ERROR&&(e.error&&typeof e.error.message=="string"?n=e.error.message:typeof e.body=="string"?n=e.body:typeof e.responseText=="string"&&(n=e.responseText)),n=(n||"").toLowerCase(),n.match(/insufficient funds/)&&Va.throwError("insufficient funds for intrinsic transaction cost",E.errors.INSUFFICIENT_FUNDS,{error:e,method:a,transaction:t}),n.match(/same hash was already imported|transaction nonce is too low|nonce too low/)&&Va.throwError("nonce has already been used",E.errors.NONCE_EXPIRED,{error:e,method:a,transaction:t}),n.match(/another transaction with same nonce/)&&Va.throwError("replacement fee too low",E.errors.REPLACEMENT_UNDERPRICED,{error:e,method:a,transaction:t}),n.match(/execution failed due to an exception|execution reverted/)&&Va.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",E.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,method:a,transaction:t}),e}var Es=class extends aa{constructor(e,t){super(e),B(this,"baseUrl",this.getBaseUrl()),B(this,"apiKey",t||null)}getBaseUrl(){switch(this.network?this.network.name:"invalid"){case"homestead":return"https://api.etherscan.io";case"goerli":return"https://api-goerli.etherscan.io";case"sepolia":return"https://api-sepolia.etherscan.io";case"matic":return"https://api.polygonscan.com";case"maticmum":return"https://api-testnet.polygonscan.com";case"arbitrum":return"https://api.arbiscan.io";case"arbitrum-goerli":return"https://api-goerli.arbiscan.io";case"optimism":return"https://api-optimistic.etherscan.io";case"optimism-goerli":return"https://api-goerli-optimistic.etherscan.io";default:}return Va.throwArgumentError("unsupported network","network",this.network.name)}getUrl(e,t){let n=Object.keys(t).reduce((r,s)=>{let o=t[s];return o!=null&&(r+=`&${s}=${o}`),r},""),i=this.apiKey?`&apikey=${this.apiKey}`:"";return`${this.baseUrl}/api?module=${e}${n}${i}`}getPostUrl(){return`${this.baseUrl}/api`}getPostData(e,t){return t.module=e,t.apikey=this.apiKey,t}fetch(e,t,n){return nu(this,void 0,void 0,function*(){let i=n?this.getPostUrl():this.getUrl(e,t),r=n?this.getPostData(e,t):null,s=e==="proxy"?ff:jx;this.emit("debug",{action:"request",request:i,provider:this});let o={url:i,throttleSlotInterval:1e3,throttleCallback:(c,x)=>(this.isCommunityResource()&&na(),Promise.resolve(!0))},l=null;r&&(o.headers={"content-type":"application/x-www-form-urlencoded; charset=UTF-8"},l=Object.keys(r).map(c=>`${c}=${r[c]}`).join("&"));let p=yield On(o,l,s||ff);return this.emit("debug",{action:"response",request:i,response:mt(p),provider:this}),p})}detectNetwork(){return nu(this,void 0,void 0,function*(){return this.network})}perform(e,t){let n=Object.create(null,{perform:{get:()=>super.perform}});return nu(this,void 0,void 0,function*(){switch(e){case"getBlockNumber":return this.fetch("proxy",{action:"eth_blockNumber"});case"getGasPrice":return this.fetch("proxy",{action:"eth_gasPrice"});case"getBalance":return this.fetch("account",{action:"balance",address:t.address,tag:t.blockTag});case"getTransactionCount":return this.fetch("proxy",{action:"eth_getTransactionCount",address:t.address,tag:t.blockTag});case"getCode":return this.fetch("proxy",{action:"eth_getCode",address:t.address,tag:t.blockTag});case"getStorageAt":return this.fetch("proxy",{action:"eth_getStorageAt",address:t.address,position:t.position,tag:t.blockTag});case"sendTransaction":return this.fetch("proxy",{action:"eth_sendRawTransaction",hex:t.signedTransaction},!0).catch(i=>Dl("sendTransaction",i,t.signedTransaction));case"getBlock":if(t.blockTag)return this.fetch("proxy",{action:"eth_getBlockByNumber",tag:t.blockTag,boolean:t.includeTransactions?"true":"false"});throw new Error("getBlock by blockHash not implemented");case"getTransaction":return this.fetch("proxy",{action:"eth_getTransactionByHash",txhash:t.transactionHash});case"getTransactionReceipt":return this.fetch("proxy",{action:"eth_getTransactionReceipt",txhash:t.transactionHash});case"call":{if(t.blockTag!=="latest")throw new Error("EtherscanProvider does not support blockTag for call");let i=cf(t.transaction);i.module="proxy",i.action="eth_call";try{return yield this.fetch("proxy",i,!0)}catch(r){return Dl("call",r,t.transaction)}}case"estimateGas":{let i=cf(t.transaction);i.module="proxy",i.action="eth_estimateGas";try{return yield this.fetch("proxy",i,!0)}catch(r){return Dl("estimateGas",r,t.transaction)}}case"getLogs":{let i={action:"getLogs"};if(t.filter.fromBlock&&(i.fromBlock=mf(t.filter.fromBlock)),t.filter.toBlock&&(i.toBlock=mf(t.filter.toBlock)),t.filter.address&&(i.address=t.filter.address),t.filter.topics&&t.filter.topics.length>0&&(t.filter.topics.length>1&&Va.throwError("unsupported topic count",E.errors.UNSUPPORTED_OPERATION,{topics:t.filter.topics}),t.filter.topics.length===1)){let o=t.filter.topics[0];(typeof o!="string"||o.length!==66)&&Va.throwError("unsupported topic format",E.errors.UNSUPPORTED_OPERATION,{topic0:o}),i.topic0=o}let r=yield this.fetch("logs",i),s={};for(let o=0;o{["contractAddress","to"].forEach(function(l){s[l]==""&&delete s[l]}),s.creates==null&&s.contractAddress!=null&&(s.creates=s.contractAddress);let o=this.formatter.transactionResponse(s);return s.timeStamp&&(o.timestamp=parseInt(s.timeStamp)),o})})}isCommunityResource(){return this.apiKey==null}};var ru=function(a,e,t,n){function i(r){return r instanceof t?r:new t(function(s){s(r)})}return new(t||(t=Promise))(function(r,s){function o(c){try{p(n.next(c))}catch(x){s(x)}}function l(c){try{p(n.throw(c))}catch(x){s(x)}}function p(c){c.done?r(c.value):i(c.value).then(o,l)}p((n=n.apply(a,e||[])).next())})},_i=new E(Ae);function au(){return new Date().getTime()}function hf(a){let e=null;for(let t=0;te?null:(n+i)/2}function Cr(a){if(a===null)return"null";if(typeof a=="number"||typeof a=="boolean")return JSON.stringify(a);if(typeof a=="string")return a;if(F.isBigNumber(a))return a.toString();if(Array.isArray(a))return JSON.stringify(a.map(e=>Cr(e)));if(typeof a=="object"){let e=Object.keys(a);return e.sort(),"{"+e.map(t=>{let n=a[t];return typeof n=="function"?n="[function]":n=Cr(n),JSON.stringify(t)+":"+n}).join(",")+"}"}throw new Error("unknown value type: "+typeof a)}var Hx=1;function bf(a){let e=null,t=null,n=new Promise(s=>{e=function(){t&&(clearTimeout(t),t=null),s()},t=setTimeout(e,a)}),i=s=>(n=n.then(s),n);function r(){return n}return{cancel:e,getPromise:r,wait:i}}var qx=[E.errors.CALL_EXCEPTION,E.errors.INSUFFICIENT_FUNDS,E.errors.NONCE_EXPIRED,E.errors.REPLACEMENT_UNDERPRICED,E.errors.UNPREDICTABLE_GAS_LIMIT],zx=["address","args","errorArgs","errorSignature","method","transaction"];function iu(a,e){let t={weight:a.weight};return Object.defineProperty(t,"provider",{get:()=>a.provider}),a.start&&(t.start=a.start),e&&(t.duration=e-a.start),a.done&&(a.error?t.error=a.error:t.result=a.result||null),t}function Gx(a,e){return function(t){let n={};t.forEach(r=>{let s=a(r.result);n[s]||(n[s]={count:0,result:r.result}),n[s].count++});let i=Object.keys(n);for(let r=0;r=e)return s.result}}}function Wx(a,e,t){let n=Cr;switch(e){case"getBlockNumber":return function(i){let r=i.map(o=>o.result),s=xf(i.map(o=>o.result),2);if(s!=null)return s=Math.ceil(s),r.indexOf(s+1)>=0&&s++,s>=a._highestBlockNumber&&(a._highestBlockNumber=s),a._highestBlockNumber};case"getGasPrice":return function(i){let r=i.map(s=>s.result);return r.sort(),r[Math.floor(r.length/2)]};case"getEtherPrice":return function(i){return xf(i.map(r=>r.result))};case"getBalance":case"getTransactionCount":case"getCode":case"getStorageAt":case"call":case"estimateGas":case"getLogs":break;case"getTransaction":case"getTransactionReceipt":n=function(i){return i==null?null:(i=_e(i),i.confirmations=-1,Cr(i))};break;case"getBlock":t.includeTransactions?n=function(i){return i==null?null:(i=_e(i),i.transactions=i.transactions.map(r=>(r=_e(r),r.confirmations=-1,r)),Cr(i))}:n=function(i){return i==null?null:Cr(i)};break;default:throw new Error("unknown method: "+e)}return Gx(n,a.quorum)}function Ms(a,e){return ru(this,void 0,void 0,function*(){let t=a.provider;return t.blockNumber!=null&&t.blockNumber>=e||e===-1?t:Bn(()=>new Promise((n,i)=>{setTimeout(function(){return t.blockNumber>=e?n(t):a.cancelled?n(null):n(void 0)},0)}),{oncePoll:t})})}function Kx(a,e,t,n){return ru(this,void 0,void 0,function*(){let i=a.provider;switch(t){case"getBlockNumber":case"getGasPrice":return i[t]();case"getEtherPrice":if(i.getEtherPrice)return i.getEtherPrice();break;case"getBalance":case"getTransactionCount":case"getCode":return n.blockTag&&ie(n.blockTag)&&(i=yield Ms(a,e)),i[t](n.address,n.blockTag||"latest");case"getStorageAt":return n.blockTag&&ie(n.blockTag)&&(i=yield Ms(a,e)),i.getStorageAt(n.address,n.position,n.blockTag||"latest");case"getBlock":return n.blockTag&&ie(n.blockTag)&&(i=yield Ms(a,e)),i[n.includeTransactions?"getBlockWithTransactions":"getBlock"](n.blockTag||n.blockHash);case"call":case"estimateGas":return n.blockTag&&ie(n.blockTag)&&(i=yield Ms(a,e)),t==="call"&&n.blockTag?i[t](n.transaction,n.blockTag):i[t](n.transaction);case"getTransaction":case"getTransactionReceipt":return i[t](n.transactionHash);case"getLogs":{let r=n.filter;return(r.fromBlock&&ie(r.fromBlock)||r.toBlock&&ie(r.toBlock))&&(i=yield Ms(a,e)),i.getLogs(r)}}return _i.throwError("unknown method error",E.errors.UNKNOWN_ERROR,{method:t,params:n})})}var Is=class extends aa{constructor(e,t){e.length===0&&_i.throwArgumentError("missing providers","providers",e);let n=e.map((s,o)=>{if(Xt.isProvider(s)){let c=hs(s)?2e3:750;return Object.freeze({provider:s,weight:1,stallTimeout:c,priority:1})}let l=_e(s);l.priority==null&&(l.priority=1),l.stallTimeout==null&&(l.stallTimeout=hs(s)?2e3:750),l.weight==null&&(l.weight=1);let p=l.weight;return(p%1||p>512||p<1)&&_i.throwArgumentError("invalid weight; must be integer in [1, 512]",`providers[${o}].weight`,p),Object.freeze(l)}),i=n.reduce((s,o)=>s+o.weight,0);t==null?t=i/2:t>i&&_i.throwArgumentError("quorum will always fail; larger than total weight","quorum",t);let r=hf(n.map(s=>s.provider.network));r==null&&(r=new Promise((s,o)=>{setTimeout(()=>{this.detectNetwork().then(s,o)},0)})),super(r),B(this,"providerConfigs",Object.freeze(n)),B(this,"quorum",t),this._highestBlockNumber=-1}detectNetwork(){return ru(this,void 0,void 0,function*(){let e=yield Promise.all(this.providerConfigs.map(t=>t.provider.getNetwork()));return hf(e)})}perform(e,t){return ru(this,void 0,void 0,function*(){if(e==="sendTransaction"){let l=yield Promise.all(this.providerConfigs.map(p=>p.provider.sendTransaction(t.signedTransaction).then(c=>c.hash,c=>c)));for(let p=0;pl.priority-p.priority);let r=this._highestBlockNumber,s=0,o=!0;for(;;){let l=au(),p=i.filter(_=>_.runner&&l-_.start<_.stallTimeout).reduce((_,v)=>_+v.weight,0);for(;p{_.staller=null}),_.runner=Kx(_,r,e,t).then(S=>{_.done=!0,_.result=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:iu(_,au()),request:{method:e,params:mt(t)},provider:this})},S=>{_.done=!0,_.error=S,this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:iu(_,au()),request:{method:e,params:mt(t)},provider:this})}),this.listenerCount("debug")&&this.emit("debug",{action:"request",rid:v,backend:iu(_,null),request:{method:e,params:mt(t)},provider:this}),p+=_.weight}let c=[];i.forEach(_=>{_.done||!_.runner||(c.push(_.runner),_.staller&&c.push(_.staller.getPromise()))}),c.length&&(yield Promise.race(c));let x=i.filter(_=>_.done&&_.error==null);if(x.length>=this.quorum){let _=n(x);if(_!==void 0)return i.forEach(v=>{v.staller&&v.staller.cancel(),v.cancelled=!0}),_;o||(yield bf(100).getPromise()),o=!1}let C=i.reduce((_,v)=>{if(!v.done||v.error==null)return _;let S=v.error.code;return qx.indexOf(S)>=0&&(_[S]||(_[S]={error:v.error,weight:0}),_[S].weight+=v.weight),_},{});if(Object.keys(C).forEach(_=>{let v=C[_];if(v.weight{O.staller&&O.staller.cancel(),O.cancelled=!0});let S=v.error,L={};zx.forEach(O=>{S[O]!=null&&(L[O]=S[O])}),_i.throwError(S.reason||S.message,_,L)}),i.filter(_=>!_.done).length===0)break}return i.forEach(l=>{l.staller&&l.staller.cancel(),l.cancelled=!0}),_i.throwError("failed to meet quorum",E.errors.SERVER_ERROR,{method:e,params:t,results:i.map(l=>iu(l)),provider:this})})}};var Ol=null;var su=new E(Ae),Cs="84842078b09946638c03157f83405213",Ss=class extends _a{constructor(e,t){let n=new Sr(e,t),i=n.connection;i.password&&su.throwError("INFURA WebSocket project secrets unsupported",E.errors.UNSUPPORTED_OPERATION,{operation:"InfuraProvider.getWebSocketProvider()"});let r=i.url.replace(/^http/i,"ws").replace("/v3/","/ws/v3/");super(r,e),B(this,"apiKey",n.projectId),B(this,"projectId",n.projectId),B(this,"projectSecret",n.projectSecret)}isCommunityResource(){return this.projectId===Cs}},Sr=class extends St{static getWebSocketProvider(e,t){return new Ss(e,t)}static getApiKey(e){let t={apiKey:Cs,projectId:Cs,projectSecret:null};return e==null||(typeof e=="string"?t.projectId=e:e.projectSecret!=null?(su.assertArgument(typeof e.projectId=="string","projectSecret requires a projectId","projectId",e.projectId),su.assertArgument(typeof e.projectSecret=="string","invalid projectSecret","projectSecret","[REDACTED]"),t.projectId=e.projectId,t.projectSecret=e.projectSecret):e.projectId&&(t.projectId=e.projectId),t.apiKey=t.projectId),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"homestead":n="mainnet.infura.io";break;case"goerli":n="goerli.infura.io";break;case"sepolia":n="sepolia.infura.io";break;case"matic":n="polygon-mainnet.infura.io";break;case"maticmum":n="polygon-mumbai.infura.io";break;case"optimism":n="optimism-mainnet.infura.io";break;case"optimism-goerli":n="optimism-goerli.infura.io";break;case"arbitrum":n="arbitrum-mainnet.infura.io";break;case"arbitrum-goerli":n="arbitrum-goerli.infura.io";break;default:su.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i={allowGzip:!0,url:"https://"+n+"/v3/"+t.projectId,throttleCallback:(r,s)=>(t.projectId===Cs&&na(),Promise.resolve(!0))};return t.projectSecret!=null&&(i.user="",i.password=t.projectSecret),i}isCommunityResource(){return this.projectId===Cs}};var ou=class extends tn{send(e,t){let n={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this._pendingBatch==null&&(this._pendingBatch=[]);let i={request:n,resolve:null,reject:null},r=new Promise((s,o)=>{i.resolve=s,i.reject=o});return this._pendingBatch.push(i),this._pendingBatchAggregator||(this._pendingBatchAggregator=setTimeout(()=>{let s=this._pendingBatch;this._pendingBatch=null,this._pendingBatchAggregator=null;let o=s.map(l=>l.request);return this.emit("debug",{action:"requestBatch",request:mt(o),provider:this}),On(this.connection,JSON.stringify(o)).then(l=>{this.emit("debug",{action:"response",request:o,response:l,provider:this}),s.forEach((p,c)=>{let x=l[c];if(x.error){let C=new Error(x.error.message);C.code=x.error.code,C.data=x.error.data,p.reject(C)}else p.resolve(x.result)})},l=>{this.emit("debug",{action:"response",error:l,request:o,provider:this}),s.forEach(p=>{p.reject(l)})})},10)),r}};var Bl=new E(Ae),Jx="ETHERS_JS_SHARED",Rs=class extends St{static getApiKey(e){return e&&typeof e!="string"&&Bl.throwArgumentError("invalid apiKey","apiKey",e),e||Jx}static getUrl(e,t){Bl.warn("NodeSmith will be discontinued on 2019-12-20; please migrate to another platform.");let n=null;switch(e.name){case"homestead":n="https://ethereum.api.nodesmith.io/v1/mainnet/jsonrpc";break;case"ropsten":n="https://ethereum.api.nodesmith.io/v1/ropsten/jsonrpc";break;case"rinkeby":n="https://ethereum.api.nodesmith.io/v1/rinkeby/jsonrpc";break;case"goerli":n="https://ethereum.api.nodesmith.io/v1/goerli/jsonrpc";break;case"kovan":n="https://ethereum.api.nodesmith.io/v1/kovan/jsonrpc";break;default:Bl.throwArgumentError("unsupported network","network",arguments[0])}return n+"?apiKey="+t}};var gf=new E(Ae),Tf="62e1ad51b37b8e00394bda3b",Ps=class extends St{static getApiKey(e){let t={applicationId:null,loadBalancer:!0,applicationSecretKey:null};return e==null?t.applicationId=Tf:typeof e=="string"?t.applicationId=e:e.applicationSecretKey!=null?(t.applicationId=e.applicationId,t.applicationSecretKey=e.applicationSecretKey):e.applicationId?t.applicationId=e.applicationId:gf.throwArgumentError("unsupported PocketProvider apiKey","apiKey",e),t}static getUrl(e,t){let n=null;switch(e?e.name:"unknown"){case"goerli":n="eth-goerli.gateway.pokt.network";break;case"homestead":n="eth-mainnet.gateway.pokt.network";break;case"kovan":n="poa-kovan.gateway.pokt.network";break;case"matic":n="poly-mainnet.gateway.pokt.network";break;case"maticmum":n="polygon-mumbai-rpc.gateway.pokt.network";break;case"rinkeby":n="eth-rinkeby.gateway.pokt.network";break;case"ropsten":n="eth-ropsten.gateway.pokt.network";break;default:gf.throwError("unsupported network",E.errors.INVALID_ARGUMENT,{argument:"network",value:e})}let i=`https://${n}/v1/lb/${t.applicationId}`,r={headers:{},url:i};return t.applicationSecretKey!=null&&(r.user="",r.password=t.applicationSecretKey),r}isCommunityResource(){return this.applicationId===Tf}};var vf=new E(Ae),$x=1;function wf(a,e){let t="Web3LegacyFetcher";return function(n,i){let r={method:n,params:i,id:$x++,jsonrpc:"2.0"};return new Promise((s,o)=>{this.emit("debug",{action:"request",fetcher:t,request:mt(r),provider:this}),e(r,(l,p)=>{if(l)return this.emit("debug",{action:"response",fetcher:t,error:l,request:r,provider:this}),o(l);if(this.emit("debug",{action:"response",fetcher:t,request:r,response:p,provider:this}),p.error){let c=new Error(p.error.message);return c.code=p.error.code,c.data=p.error.data,o(c)}s(p.result)})})}}function Qx(a){return function(e,t){t==null&&(t=[]);let n={method:e,params:t};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:mt(n),provider:this}),a.request(n).then(i=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,response:i,provider:this}),i),i=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:n,error:i,provider:this}),i})}}var Ns=class extends tn{constructor(e,t){e==null&&vf.throwArgumentError("missing provider","provider",e);let n=null,i=null,r=null;typeof e=="function"?(n="unknown:",i=e):(n=e.host||e.path||"",!n&&e.isMetaMask&&(n="metamask"),r=e,e.request?(n===""&&(n="eip-1193:"),i=Qx(e)):e.sendAsync?i=wf(e,e.sendAsync.bind(e)):e.send?i=wf(e,e.send.bind(e)):vf.throwArgumentError("unsupported provider","provider",e),n||(n="unknown:")),super(n,t),B(this,"jsonRpcFetchFunc",i),B(this,"provider",r)}send(e,t){return this.jsonRpcFetchFunc(e,t)}};var _f=new E(Ae);function uu(a,e){if(a==null&&(a="homestead"),typeof a=="string"){let n=a.match(/^(ws|http)s?:/i);if(n)switch(n[1].toLowerCase()){case"http":case"https":return new tn(a);case"ws":case"wss":return new _a(a);default:_f.throwArgumentError("unsupported URL scheme","network",a)}}let t=cs(a);return(!t||!t._defaultProvider)&&_f.throwError("unsupported getDefaultProvider network",E.errors.NETWORK_ERROR,{operation:"getDefaultProvider",network:a}),t._defaultProvider({FallbackProvider:Is,AlchemyProvider:Ir,AnkrProvider:ks,CloudflareProvider:As,EtherscanProvider:Es,InfuraProvider:Sr,JsonRpcProvider:tn,NodesmithProvider:Rs,PocketProvider:Ps,Web3Provider:Ns,IpcProvider:null},e)}var te={};Ki(te,{AbiCoder:()=>nr,ConstructorFragment:()=>Lt,ErrorFragment:()=>rn,EventFragment:()=>Wt,FormatTypes:()=>ge,Fragment:()=>Kt,FunctionFragment:()=>Ut,HDNode:()=>Ct,Indexed:()=>pa,Interface:()=>Da,LogDescription:()=>sr,Logger:()=>E,ParamType:()=>yt,RLP:()=>io,SigningKey:()=>bn,SupportedAlgorithm:()=>ea,TransactionDescription:()=>or,TransactionTypes:()=>Do,UnicodeNormalizationForm:()=>Jt,Utf8ErrorFuncs:()=>bo,Utf8ErrorReason:()=>Vt,_TypedDataEncoder:()=>gt,_fetchData:()=>_l,_toEscapedUtf8String:()=>Id,accessListify:()=>dn,arrayify:()=>j,base58:()=>ha,base64:()=>Dd,checkProperties:()=>Qi,checkResultErrors:()=>Xi,commify:()=>Rf,computeAddress:()=>gn,computeHmac:()=>xa,computePublicKey:()=>rs,concat:()=>ye,deepCopy:()=>mt,defaultAbiCoder:()=>es,defaultPath:()=>ba,defineReadOnly:()=>B,dnsEncode:()=>ns,entropyToMnemonic:()=>wi,fetchJson:()=>On,formatBytes32String:()=>Cd,formatEther:()=>Pf,formatUnits:()=>Fl,getAccountPath:()=>wc,getAddress:()=>fe,getContractAddress:()=>ci,getCreate2Address:()=>By,getIcapAddress:()=>Oy,getJsonWalletAddress:()=>bl,getStatic:()=>ht,hashMessage:()=>rr,hexConcat:()=>At,hexDataLength:()=>Ft,hexDataSlice:()=>Ce,hexStripZeros:()=>xd,hexValue:()=>Hn,hexZeroPad:()=>me,hexlify:()=>W,id:()=>sn,isAddress:()=>Dy,isBytes:()=>pn,isBytesLike:()=>oa,isHexString:()=>ie,isValidMnemonic:()=>vc,isValidName:()=>Bd,joinSignature:()=>zr,keccak256:()=>ce,mnemonicToEntropy:()=>Tr,mnemonicToSeed:()=>pl,namehash:()=>Na,nameprep:()=>Nd,parseBytes32String:()=>Sd,parseEther:()=>Nf,parseTransaction:()=>Oo,parseUnits:()=>Ll,poll:()=>Bn,randomBytes:()=>ta,recoverAddress:()=>xi,recoverPublicKey:()=>No,resolveProperties:()=>Se,ripemd160:()=>us,serializeTransaction:()=>ss,sha256:()=>en,sha512:()=>ol,shallowCopy:()=>_e,shuffled:()=>ps,solidityKeccak256:()=>Ef,solidityPack:()=>du,soliditySha256:()=>Mf,splitSignature:()=>qn,stripZeros:()=>nn,toUtf8Bytes:()=>ve,toUtf8CodePoints:()=>Pa,toUtf8String:()=>Yt,verifyMessage:()=>Uc,verifyTypedData:()=>Vc,zeroPad:()=>di});var kf="solidity/5.7.0";var Yx=new RegExp("^bytes([0-9]+)$"),Xx=new RegExp("^(u?int)([0-9]*)$"),Zx=new RegExp("^(.*)\\[([0-9]*)\\]$"),eb="0000000000000000000000000000000000000000000000000000000000000000",Rr=new E(kf);function Af(a,e,t){switch(a){case"address":return t?di(e,32):j(e);case"string":return ve(e);case"bytes":return j(e);case"bool":return e=e?"0x01":"0x00",t?di(e,32):j(e)}let n=a.match(Xx);if(n){let i=parseInt(n[2]||"256");return(n[2]&&String(i)!==n[2]||i%8!==0||i===0||i>256)&&Rr.throwArgumentError("invalid number type","type",a),t&&(i=256),e=F.from(e).toTwos(i),di(e,i/8)}if(n=a.match(Yx),n){let i=parseInt(n[1]);return(String(i)!==n[1]||i===0||i>32)&&Rr.throwArgumentError("invalid bytes type","type",a),j(e).byteLength!==i&&Rr.throwArgumentError(`invalid value for ${a}`,"value",e),t?j((e+eb).substring(0,66)):e}if(n=a.match(Zx),n&&Array.isArray(e)){let i=n[1];parseInt(n[2]||String(e.length))!=e.length&&Rr.throwArgumentError(`invalid array length for ${a}`,"value",e);let s=[];return e.forEach(function(o){s.push(Af(i,o,!0))}),ye(s)}return Rr.throwArgumentError("invalid type","type",a)}function du(a,e){a.length!=e.length&&Rr.throwArgumentError("wrong number of values; expected ${ types.length }","values",e);let t=[];return a.forEach(function(n,i){t.push(Af(n,e[i]))}),W(ye(t))}function Ef(a,e){return ce(du(a,e))}function Mf(a,e){return en(du(a,e))}var If="units/5.7.0";var Cf=new E(If),Sf=["wei","kwei","mwei","gwei","szabo","finney","ether"];function Rf(a){let e=String(a).split(".");(e.length>2||!e[0].match(/^-?[0-9]*$/)||e[1]&&!e[1].match(/^[0-9]*$/)||a==="."||a==="-.")&&Cf.throwArgumentError("invalid value","value",a);let t=e[0],n="";for(t.substring(0,1)==="-"&&(n="-",t=t.substring(1));t.substring(0,1)==="0";)t=t.substring(1);t===""&&(t="0");let i="";for(e.length===2&&(i="."+(e[1]||"0"));i.length>2&&i[i.length-1]==="0";)i=i.substring(0,i.length-1);let r=[];for(;t.length;)if(t.length<=3){r.unshift(t);break}else{let s=t.length-3;r.unshift(t.substring(s)),t=t.substring(0,s)}return n+r.join(",")+i}function Fl(a,e){if(typeof e=="string"){let t=Sf.indexOf(e);t!==-1&&(e=3*t)}return $i(a,e??18)}function Ll(a,e){if(typeof a!="string"&&Cf.throwArgumentError("value must be a string","value",a),typeof e=="string"){let t=Sf.indexOf(e);t!==-1&&(e=3*t)}return cn(a,e??18)}function Pf(a){return Fl(a,18)}function Nf(a){return Ll(a,18)}var lu="ethers/5.7.2";var Df=new E(lu);try{let a=window;a._ethers==null&&(a._ethers=Ul)}catch{}var Fn;(function(a){a.Mainnet="Mainnet",a.Custom="Custom",a.Gnosis="Xdai",a.Goerli="Goerli",a.Xdai="Xdai",a.XdaiQa="XdaiQa"})(Fn||(Fn={}));var pu;(function(a){a.Mainnet="0x5346D0f80e2816FaD329F2c140c870ffc3c3E2Ef",a.Goerli="0x79073fc2117dD054FCEdaCad1E7018C9CbE3ec0B",a.Xdai="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.XdaiQa="0x78163f593D1Fa151B4B7cacD146586aD2b686294",a.Custom=""})(pu||(pu={}));var Pr;(function(a){a.Mainnet="https://colony.io/reputation/mainnet",a.Goerli="https://colony.io/reputation/goerli",a.Xdai="https://xdai.colony.io/reputation/xdai",a.XdaiQa="https://qa-xdai.colony.io/reputation/xdai",a.Custom="http://localhost:3000"})(Pr||(Pr={}));var yu;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/metatransaction/xdai",a.Xdai="https://xdai.colony.io/metatransaction/xdai",a.XdaiQa="https://xdai.colony.io/metatransaction/xdai",a.Custom=""})(yu||(yu={}));var Vl;(function(a){a.Mainnet="",a.Goerli="",a.Gnosis="https://xdai.colony.io/rpc/",a.Xdai="https://xdai.colony.io/rpc/",a.XdaiQa="https://xdai.colony.io/rpc/",a.Custom=""})(Vl||(Vl={}));var Ds;(function(a){a.Mainnet=".colony.joincolony.eth",a.Goerli=".colony.joincolony.test",a.Gnosis=".colony.joincolony.colonyxdai",a.Xdai=".colony.joincolony.colonyxdai",a.XdaiQa=".colony.joincolony.colonyxdai",a.Custom=".colony.joincolony.test"})(Ds||(Ds={}));var Os;(function(a){a.Mainnet=".user.joincolony.eth",a.Goerli=".user.joincolony.test",a.Gnosis=".user.joincolony.colonyxdai",a.Xdai=".user.joincolony.colonyxdai",a.XdaiQa=".user.joincolony.colonyxdai",a.Custom=".user.joincolony.test"})(Os||(Os={}));var jl;(function(a){let e;(function(n){n.ETH="0x0000000000000000000000000000000000000000",n.Mainnet="0x3E828ac5C480069D4765654Fb4b8733b910b13b2"})(e=a.Mainnet||(a.Mainnet={}));let t;(function(n){n.XDAI="0x0000000000000000000000000000000000000000",n.CLNY="0xc9B6218AffE8Aba68a13899Cbf7cF7f14DDd304C"})(t=a.Gnosis||(a.Gnosis={}))})(jl||(jl={}));var ke;(function(a){a[a.RootDomain=1]="RootDomain",a[a.RootTeam=1]="RootTeam",a[a.RootPot=1]="RootPot",a[a.SkillIgnore=0]="SkillIgnore"})(ke||(ke={}));var Ot;(function(a){a[a.Null=0]="Null",a[a.Staking=1]="Staking",a[a.Submit=2]="Submit",a[a.Reveal=3]="Reveal",a[a.Closed=4]="Closed",a[a.Finalizable=5]="Finalizable",a[a.Finalized=6]="Finalized",a[a.Failed=7]="Failed"})(Ot||(Ot={}));var ql="0x12345678",Hl;(function(a){a[a.Unassigned=0]="Unassigned",a[a.Domain=1]="Domain",a[a.Task=2]="Task",a[a.Payment=3]="Payment",a[a.Expenditure=4]="Expenditure"})(Hl||(Hl={}));var wt;(function(a){a[a.Recovery=0]="Recovery",a[a.Root=1]="Root",a[a.Arbitration=2]="Arbitration",a[a.Architecture=3]="Architecture",a[a.ArchitectureSubdomain=4]="ArchitectureSubdomain",a[a.Funding=5]="Funding",a[a.Administration=6]="Administration",a[a.LAST_ROLE=7]="LAST_ROLE"})(wt||(wt={}));var we;(function(a){a.CoinMachine="CoinMachine",a.EvaluatedExpenditure="EvaluatedExpenditure",a.FundingQueue="FundingQueue",a.IVotingReputation="IVotingReputation",a.OneTxPayment="OneTxPayment",a.ReputationBootstrapper="ReputationBootstrapper",a.StagedExpenditure="StagedExpenditure",a.StakedExpenditure="StakedExpenditure",a.StreamingPayments="StreamingPayments",a.TokenSupplier="TokenSupplier",a.VotingReputation="VotingReputation",a.Whitelist="Whitelist"})(we||(we={}));var zl=[{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"}],ki=class{static createInterface(){return new te.Interface(zl)}static connect(e,t){return new oe(e,zl,t)}};xe(ki,"abi",zl);var Gl=[{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"}],Ai=class{static createInterface(){return new te.Interface(Gl)}static connect(e,t){return new oe(e,Gl,t)}};xe(Ai,"abi",Gl);var Of=(a,e)=>{throw new Error(`${e}: ${a}`)},Wl=a=>a!=null;var{keccak256:nb,toUtf8Bytes:ab}=te,{MaxUint256:ib}=xt;var Nr=a=>te.formatEther(a),Dr=a=>te.parseEther(a);var Kl=a=>{let e=a.reduce((t,n)=>t|1<{let e=F.from(a);return[...Array(wt.LAST_ROLE).keys()].map(t=>e.shr(t).mask(1).eq(1)?t:null).filter(Wl)},Ei=async(a,e,t,n)=>{if(F.from(t).eq(F.from(n)))return ib;let{skillId:i}=await e.getDomain(t),{skillId:r}=await e.getDomain(n),{children:s}=await a.getSkill(i),o=s.findIndex(l=>l.eq(r));if(o<0)throw new Error(`Could not find ${n} as a child of ${t}`);return F.from(o)},ja=a=>nb(ab(a));var Or=async(a,e)=>(await Ai.connect(a,e).version()).toNumber(),Jl=(a,e)=>a.map(t=>{try{return e.parseLog(t)}catch{return null}}).filter(Wl);var{hexDataSlice:$l}=te,{MaxUint256:rb}=xt,Bf=a=>{let e=$l(a,0,3),t=F.from($l(a,4,35)),n=F.from($l(a,36,67));return{sig:e,permissionDomainId:t,childSkillIndex:n}},Ff=async(a,e,t,n,i)=>{let r=i||await e.signer?.getAddress();if(!r)throw new Error("Could not determine address for permission proofs. Please use a signer or provide a custom address");if(await e.hasUserRole(r,t,n))return[F.from(t),rb,r];let o=F.from(ke.RootDomain);if(!await e.hasUserRole(r,o,n))throw new Error(`${r} does not have the permission ${n} in any parent domain`);let p=await Ei(a,e,o,t);if(p.lt(0))throw new Error(`${r} does not have the permission ${n} in any parent domain`);return[o,p,r]},sb=async(a,e,t,n,i)=>{let r=await Promise.all(n.map(s=>Ff(a,e,t,s,i)));for(let s=0;sArray.isArray(n)?n.length===1?ra(a,e,t,n[0],i):sb(a,e,t,n,i):Ff(a,e,t,n,i);var{MaxUint256:Lf}=xt,{AddressZero:ob}=xt;async function ub(a,e){let t;try{return t=await a.getCapabilityRoles(te.hexZeroPad(e,4)),cu(t)}catch{return[]}}async function Bs(a,e,t,n,i,r,s){let o,{skillId:l}=await e.getDomain(i),{sig:p,permissionDomainId:c,childSkillIndex:x}=Bf(s),C=ki.connect(r,n.signer||n.provider),_=await ub(C,p);if(_.includes(wt.Root)||_.length===0){if(!F.from(i).eq(1))throw new Error(`On root or not permissioned actions, the domainId needs to be ${ke.RootDomain}`);o=Lf}else{let{skillId:U}=await e.getDomain(c),H=await a.getChildSkillId(U,x);if(H.eq(l))o=Lf;else{let{children:M}=await a.getSkill(l),J=M.findIndex($=>$.eq(H));if(J<0)throw new Error(`Could not find ${H} as a child of ${l}`);o=F.from(J)}}let{key:v,value:S,branchMask:L,siblings:O}=await t.getReputationWithProofs(l,ob);return{actionCid:o,key:v,value:S,branchMask:L,siblings:O}}var{AddressZero:db}=xt,sa=class{static async fetchReputation(e){let t=await fetch(e);if(t.ok)return t.json();throw new Error(`No reputation entry found for query ${e}`)}colony;network;endpointUrl;constructor(e,t,n){this.colony=t,this.network=e;let i=n?.network||Fn.Gnosis;this.endpointUrl=n?.customEndpointUrl||Pr[i]}async getRootHash(e){let t=e||await this.network.getReputationRootHash();if(F.from(t).isZero())throw new Error("No reputation for given rootHash found (yet)");return t}async getBaseEndpoint(e){let t=await this.getRootHash(e);return`${this.endpointUrl}/${t}/${this.colony.address}`}async getReputation(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}/noProof`,o=await sa.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationWithProofs(e,t,n){let i=await this.getBaseEndpoint(n),r=F.from(e||0).toString(),s=`${i}/${r}/${t}`,o=await sa.fetchReputation(s);return{...o,reputationAmount:F.from(o.reputationAmount||0)}}async getReputationAcrossDomains(e,t){let i=`${await this.getBaseEndpoint(t)}/${e}/all`,r=await sa.fetchReputation(i),s=await this.colony.getDomainCount();return(await Promise.all(Array.from(new Array(s.toNumber())).map(async(l,p)=>{let c=p+1,x=await this.colony.getDomain(c);return{domainId:c,skillId:x.skillId.toNumber()}}))||[]).map(l=>{let p,c=(r?.reputations||[]).find(({skill_id:x})=>x===l.skillId);return c&&(p=c?.reputationAmount),{...l,reputationAmount:p?F.from(p):void 0}})}async getMembersReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}`;return sa.fetchReputation(r)}async getTotalReputation(e,t){let n=await this.getBaseEndpoint(t),i=F.from(e||0).toString(),r=`${n}/${i}/${db}/noProof`,s=await sa.fetchReputation(r);return{...s,reputationAmount:F.from(s.reputationAmount||0)}}async getReputationFraction(e,t,n,i=3){let{reputationAmount:r}=await this.getReputation(e,t,n),{reputationAmount:s}=await this.getTotalReputation(e,n);return r.mul(F.from(10).pow(i)).div(s).toNumber()/10**i}};var kt=a=>Array.from(Array(a-1)).map(e=>e+1);var Uf=10,dA=kt(Uf),Vf={1:[],2:[],3:[],4:[],5:[],6:[],7:[],8:[],9:[]},jf=Uf-1;var Hf=6,yA=kt(Hf),qf={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3],5:[1,2,3]},zf=Hf-1;var Gf=7,mA=kt(Gf),Wf={1:[],2:[],3:[],4:[],5:[],6:[]},Kf=Gf-1;var Jf=7,bA=kt(Jf),$f={1:[],2:[],3:[],4:[],5:[],6:[]},Qf=Jf-1;var Yf=4,vA=kt(Yf),Xf={1:[],2:[],3:[]},Zf=Yf-1;var em=5,kA=kt(em),tm={1:[1,2,3],2:[1,2,3],3:[1,2,3],4:[1,2,3]},nm=em-1;var am=2,MA=kt(am),im={1:[1,2,3,4,5,6,7,8,9,10,11,12,13]},rm=am-1;var sm=4,SA=kt(sm),om={1:[1,2,3],2:[1,2,3],3:[1,2,3]},um=sm-1;var dm=7,NA=kt(dm),lm={1:[],2:[],3:[],4:[],5:[],6:[]},pm=dm-1;var ym=11,BA=kt(ym),Ql={1:[],2:[1,2,3,4,5,6],3:[1,2,3,4,5,6],4:[1,2,3,4,5,6],5:[1,2,3,4,5,6],6:[1,2,3,4,5,6],7:[1,2,3,4,5,6],8:[1,2,3,4,5,6],9:[1,2,3,4,5,6],10:[1,2,3,4,5,6]},Yl=ym-1;var cm=6,UA=kt(cm),fm={1:[],2:[],3:[],4:[],5:[]},mm=cm-1;var Ha=(a,e,t)=>{switch(a){case we.CoinMachine:{let n=Vf[e];return!!n&&!n.includes(t)}case we.EvaluatedExpenditure:{let n=qf[e];return!!n&&!n.includes(t)}case we.FundingQueue:{let n=Wf[e];return!!n&&!n.includes(t)}case we.IVotingReputation:{let n=Ql[e];return!!n&&!n.includes(t)}case we.OneTxPayment:{let n=$f[e];return!!n&&!n.includes(t)}case we.ReputationBootstrapper:{let n=Xf[e];return!!n&&!n.includes(t)}case we.StagedExpenditure:{let n=im[e];return!!n&&!n.includes(t)}case we.StakedExpenditure:{let n=tm[e];return!!n&&!n.includes(t)}case we.StreamingPayments:{let n=om[e];return!!n&&!n.includes(t)}case we.TokenSupplier:{let n=lm[e];return!!n&&!n.includes(t)}case we.VotingReputation:{let n=Ql[e];return!!n&&!n.includes(t)}case we.Whitelist:{let n=fm[e];return!!n&&!n.includes(t)}default:return Of(a,"Could not find extension with name")}};var lb={[we.CoinMachine]:jf,[we.EvaluatedExpenditure]:zf,[we.FundingQueue]:Kf,[we.IVotingReputation]:Yl,[we.OneTxPayment]:Qf,[we.ReputationBootstrapper]:Zf,[we.StagedExpenditure]:rm,[we.StakedExpenditure]:nm,[we.StreamingPayments]:um,[we.TokenSupplier]:pm,[we.VotingReputation]:Yl,[we.Whitelist]:mm};var Fh=Mn(hm(),1);var gp=Mn(Dh(),1);var Pe;(function(a){a.DEFAULT="default",a.Annotation="annotation",a.Colony="colony",a.Decision="decision",a.Domain="domain",a.Misc="misc"})(Pe||(Pe={}));var bp=2,xp;(function(a){a[a.LightPink=0]="LightPink",a[a.Pink=1]="Pink",a[a.Black=2]="Black",a[a.EmeraldGreen=3]="EmeraldGreen",a[a.Blue=4]="Blue",a[a.Yellow=5]="Yellow",a[a.Red=6]="Red",a[a.Green=7]="Green",a[a.Periwinkle=8]="Periwinkle",a[a.Gold=9]="Gold",a[a.Aqua=10]="Aqua",a[a.BlueGrey=11]="BlueGrey",a[a.Purple=12]="Purple",a[a.Orange=13]="Orange",a[a.Magenta=14]="Magenta",a[a.PurpleGrey=15]="PurpleGrey"})(xp||(xp={}));var Oh=a=>`Validation error(s): ${a.map(t=>`Error in ${t.path}. Seen: ${t.value}, expected: ${t.expected}`).join(` -`)}`,_1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),Tp=(a,e)=>{let t=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=gp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==bp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Pe.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Oh(t.errors);throw new Error(n)};var Bh=(a,e)=>{let t=a===Pe.Colony?_1(e):e,n=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=gp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({type:a,data:t,version:bp});if(!n.success){let i=Oh(n.errors);throw new Error(i)}return n.data};var vp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},wp=vp;var _p=(0,Fh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),zs={[Pe.Annotation]:"Annotation(address,bytes32,string)",[Pe.Colony]:"ColonyMetadata(address,string)",[Pe.Decision]:"Annotation(address,bytes32,string)",[Pe.Domain]:"DomainMetadata(address,uint256,string)",[Pe.Misc]:"",[Pe.DEFAULT]:""},Vr=class{adapter;constructor(e){this.adapter=e||new wp}static eventSupportsMetadata(e){return!!Object.keys(zs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await _p(n)).json();return Tp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await _p(n)).json(),s=Object.entries(zs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return Tp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await _p(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Bh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var yM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var kp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],kn=class{static createInterface(){return new te.Interface(kp)}static connect(e,t){return new oe(e,kp,t)}};xe(kn,"abi",kp);var Ap=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],An=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};xe(An,"abi",Ap);var Ep=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Pi=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};xe(Pi,"abi",Ep);var Ku=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Lh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",W1=a=>a.length>1,Ln=class extends gi{constructor(...e){W1(e)?super(...e):super(Ku,Lh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Ku)}static connect(e,t){return new oe(e,Ku,t)}};xe(Ln,"bytecode",Lh),xe(Ln,"abi",Ku);var Mp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};xe(Ni,"abi",Mp);var Ip=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};xe(Di,"abi",Ip);var Oi;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Oi||(Oi={}));var En;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(En||(En={}));var{AddressZero:Uh}=xt;async function $1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var Q1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Ln.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await $1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Uh)}catch{i=!1}try{await t.nonces(Uh)}catch{r=!1}return n?i?t.tokenClientType=En.Colony:(t=Ni.connect(a,e),t.tokenClientType=En.ColonyLegacy):r?(t=An.connect(a,e),t.tokenClientType=En.Erc2612):(t=kn.connect(a,e),t.tokenClientType=En.Erc20),t.clientType=Oi.TokenClient,t},Cp=Q1;var Y1=(a,e)=>{let t=Di.connect(a,e);return t.clientType=Oi.TokenLockingClient,t},Sp=Y1;var{AddressZero:Rp}=xt,X1=kn.connect(Rp,new ia.BaseProvider(3656691)).interface,Z1=Pi.connect(Rp,new ia.BaseProvider(3656691)).interface,eg=An.connect(Rp,new ia.BaseProvider(3656691)).interface;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Gs=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Gs.abi=Pp;var Np=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Ws=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Ws.abi=Np;var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Bi.abi=Dp;var ka=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,zs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:ng,solidityKeccak256:ag,splitSignature:ig}=te,Fi=class extends ka{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Fn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=ag(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=ng(l),c=await n.signMessage(p),{r:x,s:C,v:_}=ig(c),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Op=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Li=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Li.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Ui.abi=Bp;var Fp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Vi.abi=Fp;var Lp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};ji.abi=Lp;var Up=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Hi.abi=Up;var Vp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],qi=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};qi.abi=Vp;var{AddressZero:pg}=xt,Un=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(ja(Un.extensionType),e.address);if(t===pg)throw new Error(`${Un.extensionType} extension is not installed for this Colony`);let n=await Or(t,e.colonyNetwork.signerOrProvider);if(!Ha(Un.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Un.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Un.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Un.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Un(e,r,n)}static getLatestSupportedVersion(){return Un.supportedVersions[Un.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let c=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ra(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[wt.Administration,wt.Funding],this.oneTxPaymentContract.address),[S,L]=await ra(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[wt.Administration,wt.Funding]);return[_,v,S,L,c,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[ja(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},Ga=Un;Ga.supportedVersions=[{version:3,factory:ji},{version:4,factory:Hi},{version:5,factory:qi}],Ga.extensionType=we.OneTxPayment;var Vn=class{constructor(e,t){typeof t=="string"?this.tokenClient=kn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var Ks=class extends Vn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Ln.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var Js=class extends Vn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=An.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Vh=async(a,e)=>{let t=await Cp(e,a.signerOrProvider);switch(t.tokenClientType){case En.Colony:return new Ks(a,t);case En.Erc20:return new Vn(a,t);case En.Erc2612:return new Js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var jp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],zi=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};zi.abi=jp;var Hp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Gi=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};Gi.abi=Hp;var qp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Wi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};Wi.abi=qp;var{AddressZero:zp}=xt;var $u=F.from(10).pow(18),jn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(ja(jn.extensionType),e.address);if(t===zp)throw new Error(`${jn.extensionType} extension is not installed for this Colony`);let n=await Or(t,e.colonyNetwork.signerOrProvider);if(!Ha(jn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${jn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=jn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${jn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new jn(e,r,n)}static getLatestSupportedVersion(){return jn.supportedVersions[jn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Bs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,zp,ql);return[e,t,zp,ql,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Pe.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Pe.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==Ot.Staking)throw new Error(`Motion cannot be staked. It's currently in "${Ot[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Nr(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ra(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,wt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Ot.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${Ot[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:c,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,c,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Ot.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${Ot[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),c=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,c,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,c,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Ot.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${Ot[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await Ei(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:c,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,c,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==Ot.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${Ot[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[ja(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Wa=jn;Wa.supportedVersions=[{version:7,factory:zi},{version:8,factory:Gi},{version:9,factory:Wi}],Wa.extensionType=we.VotingReputation;var mg={["motion"]:Wa,["oneTx"]:Ga},Hr=class{static async connect(e,t){let n=await Or(t,e.signerOrProvider),i=Hr.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Vh(e,s),l=new Hr(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Hr.supportedVersions[Hr.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new sa(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new jr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new jr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Wa.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Ga.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Vn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Pe.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Domain,e),[ke.RootDomain,t]},{roles:wt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Pe.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:wt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Domain,e),[ke.RootDomain,t]},{roles:wt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Pe.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:wt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,c]=await ra(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,wt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await Ei(x,this.colony,r,s),_=await Ei(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,c,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Pe.Annotation})}installExtension(e){let t=mg[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Ha(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[ja(i),t.getLatestSupportedVersion()],async s=>({...Ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return cu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Kl(r);return[e,n,s]},{roles:wt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Kl(r);return[e,n,s]},{roles:wt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:wt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},qr=Hr;qr.supportedVersions=[{version:11,factory:Li},{version:12,factory:Ui},{version:13,factory:Vi}];var{splitSignature:hg}=te,Qu=class extends ka{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Fn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),c=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:c}),{r:C,s:_,v}=hg(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:c,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var $s=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Sp(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:jh}=te,{AddressZero:Gp}=xt,Qs=class{constructor(e,t){this.network=t?.network||Fn.Gnosis,this.ipfs=new Vr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||yu[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Pr[this.network]},this.networkContract=Bi.connect(t?.customNetworkAddress||pu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof Pt))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new $s(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new ka({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Fi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new Qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Gp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Pe.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Pe.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return qr.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Ds[this.network],""):null}async getColonyAddress(e){let t=jh(`${e}${Ds[this.network]}`),n=await this.networkContract.addr(t);return n!==Gp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Os[this.network],""):null}async getUserAddress(e){let t=jh(`${e}${Os[this.network]}`),n=await this.networkContract.addr(t);return n!==Gp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{isAddress:bg}=te,Hh=new ia.Web3Provider(window.ethereum),Gh,qh,Rt,ln,Kp,gg=async()=>(await Hh.send("eth_requestAccounts",[]),Hh.getSigner()),Tg=async a=>{let e=await gg();Gh=await e.getAddress(),qh=new Qs(e),Rt=await qh.getColony(a)},vg=async a=>{if(!Rt.ext.motions||!Rt.ext.oneTx)throw new Error("Motions & Disputes extension not installed");let[{motionId:e}]=await Rt.ext.oneTx.pay("0x27ff0c145e191c22c75cd123c679c3e1f58a4469",Dr(a)).motion().mined();if(!e)throw new Error("Could not get motionId from tx");return e},wg=async a=>{if(!Rt.ext.motions)throw new Error("Motions & Disputes extension not installed");let e=await Rt.ext.motions.getMotion(a);ln=F.from(a);let t=await Rt.ext.motions.getRemainingStakes(a),n=await Rt.ext.motions.getMotionState(a);return{...e,motionState:Ot[n],remainingStakes:t}},_g=async a=>{await Rt.ext.motions?.approveStake(Dr(a)).tx().mined()},kg=async a=>{await Rt.ext.motions?.stakeMotion(ln,1,a).tx().mined()},Ag=async a=>{await Rt.ext.motions?.stakeMotion(ln,0,a).tx().mined()},Eg=async()=>{await Rt.ext.motions?.submitVote(ln,1).tx().mined(),Kp=1},Mg=async()=>{await Rt.ext.motions?.submitVote(ln,0).tx().mined(),Kp=0},Ig=async()=>{await Rt.ext.motions?.revealVote(ln,Kp).tx().mined()},Cg=async()=>{await Rt.ext.motions?.finalizeMotion(ln).tx().mined()},zh=document.querySelector("#current-wallet-address"),Yu=document.querySelector("#address"),Wh=document.querySelector("#stake_clny_amount"),Wp=document.querySelector("#payment_amount"),Jp=document.querySelector("#stake_amount"),Kh=document.querySelector("#button_create_motion"),Jh=document.querySelector("#motion_id"),$h=document.querySelector("#button_connect"),Qh=document.querySelector("#button_stake_clny"),Yh=document.querySelector("#button_get_motion"),Xh=document.querySelector("#button_stake_yay"),Zh=document.querySelector("#button_stake_nay"),e6=document.querySelector("#button_vote_yay"),t6=document.querySelector("#button_vote_nay"),n6=document.querySelector("#button_reveal"),a6=document.querySelector("#button_finalize"),$p=document.querySelector("#error"),i6=document.querySelector("#result");if(!Yu||!Wh||!Wp||!Jh||!Jp||!$p||!i6||!$h||!Qh||!Kh||!Yh||!Xh||!Zh||!e6||!t6||!n6||!a6)throw new Error("Could not find all required HTML elements");var Bt=a=>{$p.innerText=`Found an error: ${a.message}`,console.error(a)},Aa=()=>{$p.innerText=""},Ie=a=>{i6.innerText=a};$h.addEventListener("click",async()=>{Aa();let a=Yu.value;if(!bg(a))return Bt(new Error("This is not a valid address"));Ie("Processing...");try{await Tg(Yu.value),zh&&(zh.innerText=Gh),Ie(` +`)}`,_1=a=>({...a,isWhitelistActivated:a.isWhitelistActivated||!1,colonySafes:a.colonySafes||[],colonyTokens:a.colonyTokens||[],verifiedAddresses:a.verifiedAddresses||[]}),Tp=(a,e)=>{let t=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=gp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})(a);if(t.success){if(t.data.version!==bp)throw new Error(`Invalid metadata version: ${t.data.version}`);if(e&&e!==t.data.name)throw new Error(`Wrong Metadata type. Given ${e}, got ${t.data.name}`);return t.data.name===Pe.Colony&&(t.data.data={...t.data.data,colonyTokens:t.data.data.colonyTokens||[],verifiedAddresses:t.data.data.verifiedAddresses||[],colonySafes:t.data.data.colonySafes||[]}),t.data}let n=Oh(t.errors);throw new Error(n)};var Bh=(a,e)=>{let t=a===Pe.Colony?_1(e):e,n=(i=>{let r=p=>{let c=M=>M.name==="colony"&&typeof M.data=="object"&&M.data!==null&&x(M.data)&&typeof M.version=="number",x=M=>typeof M.colonyName=="string"&&(M.colonyDisplayName===void 0||typeof M.colonyDisplayName=="string")&&(M.colonyAvatarHash===void 0||typeof M.colonyAvatarHash=="string")&&(M.colonyTokens===void 0||Array.isArray(M.colonyTokens)&&M.colonyTokens.every(J=>typeof J=="string"))&&(M.verifiedAddresses===void 0||Array.isArray(M.verifiedAddresses)&&M.verifiedAddresses.every(J=>typeof J=="string"))&&(M.isWhitelistActivated===void 0||typeof M.isWhitelistActivated=="boolean")&&(M.colonySafes===void 0||Array.isArray(M.colonySafes)&&M.colonySafes.every(J=>typeof J=="object"&&J!==null&&C(J))),C=M=>typeof M.chainId=="string"&&typeof M.contractAddress=="string"&&typeof M.moduleContractAddress=="string"&&typeof M.safeName=="string",_=M=>M.name==="domain"&&typeof M.data=="object"&&M.data!==null&&Array.isArray(M.data)===!1&&v(M.data)&&typeof M.version=="number",v=M=>(M.domainName===void 0||typeof M.domainName=="string")&&(M.domainColor===void 0||M.domainColor===0||M.domainColor===1||M.domainColor===2||M.domainColor===3||M.domainColor===4||M.domainColor===5||M.domainColor===6||M.domainColor===7||M.domainColor===8||M.domainColor===9||M.domainColor===10||M.domainColor===11||M.domainColor===12||M.domainColor===13||M.domainColor===14||M.domainColor===15)&&(M.domainPurpose===void 0||typeof M.domainPurpose=="string"),S=M=>M.name==="annotation"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.annotationMsg=="string"&&typeof M.version=="number",L=M=>M.name==="decision"&&typeof M.data=="object"&&M.data!==null&&O(M.data)&&typeof M.version=="number",O=M=>typeof M.title=="string"&&(M.description===void 0||typeof M.description=="string")&&typeof M.motionDomainId=="number",U=M=>M.name==="misc"&&typeof M.data=="object"&&M.data!==null&&typeof M.data.name=="string"&&typeof M.data.value=="string"&&typeof M.version=="number";return typeof p=="object"&&p!==null&&(M=>(()=>M.name==="colony"?c(M):M.name==="domain"?_(M):M.name==="annotation"?S(M):M.name==="decision"?L(M):M.name==="misc"?U(M):!1)())(p)},s=[],o=gp.default.validate.report(s);r(i)===!1&&((p,c,x=!0)=>{let C=(T,R,N=!0)=>[T.name==="colony"||o(N,{path:R+".name",expected:'"colony"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"ColonyData",value:T.data}))&&_(T.data,R+".data",N)||o(N,{path:R+".data",expected:"ColonyData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),_=(T,R,N=!0)=>[typeof T.colonyName=="string"||o(N,{path:R+".colonyName",expected:"string",value:T.colonyName}),T.colonyDisplayName===void 0||typeof T.colonyDisplayName=="string"||o(N,{path:R+".colonyDisplayName",expected:"(string | undefined)",value:T.colonyDisplayName}),T.colonyAvatarHash===void 0||typeof T.colonyAvatarHash=="string"||o(N,{path:R+".colonyAvatarHash",expected:"(string | undefined)",value:T.colonyAvatarHash}),T.colonyTokens===void 0||(Array.isArray(T.colonyTokens)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}))&&T.colonyTokens.map((q,se)=>typeof q=="string"||o(N,{path:R+".colonyTokens["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".colonyTokens",expected:"(Array | undefined)",value:T.colonyTokens}),T.verifiedAddresses===void 0||(Array.isArray(T.verifiedAddresses)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}))&&T.verifiedAddresses.map((q,se)=>typeof q=="string"||o(N,{path:R+".verifiedAddresses["+se+"]",expected:"string",value:q})).every(q=>q)||o(N,{path:R+".verifiedAddresses",expected:"(Array | undefined)",value:T.verifiedAddresses}),T.isWhitelistActivated===void 0||typeof T.isWhitelistActivated=="boolean"||o(N,{path:R+".isWhitelistActivated",expected:"(boolean | undefined)",value:T.isWhitelistActivated}),T.colonySafes===void 0||(Array.isArray(T.colonySafes)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes}))&&T.colonySafes.map((q,se)=>(typeof q=="object"&&q!==null||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q}))&&v(q,R+".colonySafes["+se+"]",N)||o(N,{path:R+".colonySafes["+se+"]",expected:"SafeInfo",value:q})).every(q=>q)||o(N,{path:R+".colonySafes",expected:"(Array | undefined)",value:T.colonySafes})].every(q=>q),v=(T,R,N=!0)=>[typeof T.chainId=="string"||o(N,{path:R+".chainId",expected:"string",value:T.chainId}),typeof T.contractAddress=="string"||o(N,{path:R+".contractAddress",expected:"string",value:T.contractAddress}),typeof T.moduleContractAddress=="string"||o(N,{path:R+".moduleContractAddress",expected:"string",value:T.moduleContractAddress}),typeof T.safeName=="string"||o(N,{path:R+".safeName",expected:"string",value:T.safeName})].every(q=>q),S=(T,R,N=!0)=>[T.name==="domain"||o(N,{path:R+".name",expected:'"domain"',value:T.name}),(typeof T.data=="object"&&T.data!==null&&Array.isArray(T.data)===!1||o(N,{path:R+".data",expected:"DomainData",value:T.data}))&&L(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DomainData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),L=(T,R,N=!0)=>[T.domainName===void 0||typeof T.domainName=="string"||o(N,{path:R+".domainName",expected:"(string | undefined)",value:T.domainName}),T.domainColor===void 0||T.domainColor===0||T.domainColor===1||T.domainColor===2||T.domainColor===3||T.domainColor===4||T.domainColor===5||T.domainColor===6||T.domainColor===7||T.domainColor===8||T.domainColor===9||T.domainColor===10||T.domainColor===11||T.domainColor===12||T.domainColor===13||T.domainColor===14||T.domainColor===15||o(N,{path:R+".domainColor",expected:"(0 | 1 | 10 | 11 | 12 | 13 | 14 | 15 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | undefined)",value:T.domainColor}),T.domainPurpose===void 0||typeof T.domainPurpose=="string"||o(N,{path:R+".domainPurpose",expected:"(string | undefined)",value:T.domainPurpose})].every(q=>q),O=(T,R,N=!0)=>[T.name==="annotation"||o(N,{path:R+".name",expected:'"annotation"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}))&&U(T.data,R+".data",N)||o(N,{path:R+".data",expected:"AnnotationData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),U=(T,R,N=!0)=>[typeof T.annotationMsg=="string"||o(N,{path:R+".annotationMsg",expected:"string",value:T.annotationMsg})].every(q=>q),H=(T,R,N=!0)=>[T.name==="decision"||o(N,{path:R+".name",expected:'"decision"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"DecisionData",value:T.data}))&&M(T.data,R+".data",N)||o(N,{path:R+".data",expected:"DecisionData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),M=(T,R,N=!0)=>[typeof T.title=="string"||o(N,{path:R+".title",expected:"string",value:T.title}),T.description===void 0||typeof T.description=="string"||o(N,{path:R+".description",expected:"(string | undefined)",value:T.description}),typeof T.motionDomainId=="number"||o(N,{path:R+".motionDomainId",expected:"number",value:T.motionDomainId})].every(q=>q),J=(T,R,N=!0)=>[T.name==="misc"||o(N,{path:R+".name",expected:'"misc"',value:T.name}),(typeof T.data=="object"&&T.data!==null||o(N,{path:R+".data",expected:"MiscData",value:T.data}))&&$(T.data,R+".data",N)||o(N,{path:R+".data",expected:"MiscData",value:T.data}),typeof T.version=="number"||o(N,{path:R+".version",expected:"number",value:T.version})].every(q=>q),$=(T,R,N=!0)=>[typeof T.name=="string"||o(N,{path:R+".name",expected:"string",value:T.name}),typeof T.value=="string"||o(N,{path:R+".value",expected:"string",value:T.value})].every(q=>q),de=(T,R,N=!0)=>(()=>T.name==="colony"?C(T,R,N):T.name==="domain"?S(T,R,N):T.name==="annotation"?O(T,R,N):T.name==="decision"?H(T,R,N):T.name==="misc"?J(T,R,N):o(N,{path:R,expected:"(ColonyMetadata | DomainMetadata | AnnotationMetadata | DecisionMetadata | MiscMetadata)",value:T}))();return(typeof p=="object"&&p!==null||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p}))&&de(p,c+"",!0)||o(!0,{path:c+"",expected:"(AnnotationMetadata | ColonyMetadata | DecisionMetadata | DomainMetadata | MiscMetadata)",value:p})})(i,"$input",!0);let l=s.length===0;return{success:l,errors:s,data:l?i:void 0}})({name:a,data:t,version:bp});if(!n.success){let i=Oh(n.errors);throw new Error(i)}return n.data};var vp=class{CLOUDFLARE_GATEWAY_ENDPOINT="https://cloudflare-ipfs.com/ipfs";name="CLOUDFLARE";getIpfsUrl(e){return`${this.CLOUDFLARE_GATEWAY_ENDPOINT}/${e}`}uploadJson(){throw new Error("The default Cloudflare IPFS adapter is readonly only. Please use another adapter to upload and pin files.")}},wp=vp;var _p=(0,Fh.default)(fetch,{headers:{Accept:"application/json"},retryOn:[404,503],retries:3,retryDelay:5e3}),zs={[Pe.Annotation]:"Annotation(address,bytes32,string)",[Pe.Colony]:"ColonyMetadata(address,string)",[Pe.Decision]:"Annotation(address,bytes32,string)",[Pe.Domain]:"DomainMetadata(address,uint256,string)",[Pe.Misc]:"",[Pe.DEFAULT]:""},Vr=class{adapter;constructor(e){this.adapter=e||new wp}static eventSupportsMetadata(e){return!!Object.keys(zs).includes(e)}async getMetadata(e,t){let n=this.adapter.getIpfsUrl(e),r=await(await _p(n)).json();return Tp(r,t)}async getMetadataForEvent(e,t){let n=this.adapter.getIpfsUrl(t),r=await(await _p(n)).json(),s=Object.entries(zs).find(([,l])=>l===e);if(!s)throw new Error(`Not a valid MetadataEvent: ${e}`);let o=s[0];return Tp(r,o)}async getRawMetadata(e){let t=this.adapter.getIpfsUrl(e),n=await _p(t);try{return await n.json()}catch(i){throw new Error(`Could not parse IPFS metadata. Original error: ${i.message}`)}}async uploadMetadata(e,t){let n=Bh(e,t),i=JSON.stringify(n);return this.adapter.uploadJson(i)}};var yM=typeof global<"u"&&global.process?global.process.env.COLONY_IPFS_PINATA_TOKEN:void 0;var kp=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"}],kn=class{static createInterface(){return new te.Interface(kp)}static connect(e,t){return new oe(e,kp,t)}};xe(kn,"abi",kp);var Ap=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"spender",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"value",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],An=class{static createInterface(){return new te.Interface(Ap)}static connect(e,t){return new oe(e,Ap,t)}};xe(An,"abi",Ap);var Ep=[{inputs:[{internalType:"string",name:"name_",type:"string"},{internalType:"string",name:"symbol_",type:"string"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"approved",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"},{indexed:!0,internalType:"address",name:"operator",type:"address"},{indexed:!1,internalType:"bool",name:"approved",type:"bool"}],name:"ApprovalForAll",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"from",type:"address"},{indexed:!0,internalType:"address",name:"to",type:"address"},{indexed:!0,internalType:"uint256",name:"tokenId",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"approve",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"getApproved",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"ownerOf",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"},{internalType:"bytes",name:"data",type:"bytes"}],name:"safeTransferFrom",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"interfaceId",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"tokenURI",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"tokenId",type:"uint256"}],name:"transferFrom",outputs:[],stateMutability:"nonpayable",type:"function"}],Pi=class{static createInterface(){return new te.Interface(Ep)}static connect(e,t){return new oe(e,Ep,t)}};xe(Pi,"abi",Ep);var Ku=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[],name:"DOMAIN_SEPARATOR",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"PERMIT_TYPEHASH",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"value",type:"uint256"},{internalType:"uint256",name:"deadline",type:"uint256"},{internalType:"uint8",name:"v",type:"uint8"},{internalType:"bytes32",name:"r",type:"bytes32"},{internalType:"bytes32",name:"s",type:"bytes32"}],name:"permit",outputs:[],stateMutability:"nonpayable",type:"function"}],Lh="0x60c06040523480156200001157600080fd5b50604051620020ca380380620020ca83398101604081905262000034916200032b565b60008060018162000044620001bd565b6001600160a01b031681526020810191909152604001600090812091909155556200006e620001bd565b600480546001600160a01b0319166001600160a01b039290921691909117905562000098620001bd565b6001600160a01b03167fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9460405160405180910390a26006620000db848262000441565b506005620000ea838262000441565b5060ff81166080526007805460ff1916600117905560405146907f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f9062000134906006906200050d565b60408051918290038220828201825260018352603160f81b6020938401528151928301939093528101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc66060820152608081018290523060a082015260c00160408051601f19818403018152919052805160209091012060a052506200058b92505050565b6000363330148015620001d1575060348110155b156200025c57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e881146200024b5733935050505090565b5001516001600160a01b0316919050565b3391505090565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200028b57600080fd5b81516001600160401b0380821115620002a857620002a862000263565b604051601f8301601f19908116603f01168101908282118183101715620002d357620002d362000263565b8160405283815260209250866020858801011115620002f157600080fd5b600091505b83821015620003155785820183015181830184015290820190620002f6565b6000602085830101528094505050505092915050565b6000806000606084860312156200034157600080fd5b83516001600160401b03808211156200035957600080fd5b620003678783880162000279565b945060208601519150808211156200037e57600080fd5b506200038d8682870162000279565b925050604084015160ff81168114620003a557600080fd5b809150509250925092565b600181811c90821680620003c557607f821691505b602082108103620003e657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200043c576000816000526020600020601f850160051c81016020861015620004175750805b601f850160051c820191505b81811015620004385782815560010162000423565b5050505b505050565b81516001600160401b038111156200045d576200045d62000263565b62000475816200046e8454620003b0565b84620003ec565b602080601f831160018114620004ad5760008415620004945750858301515b600019600386901b1c1916600185901b17855562000438565b600085815260208120601f198616915b82811015620004de57888601518255948401946001909101908401620004bd565b5085821015620004fd5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008083546200051d81620003b0565b600182811680156200053857600181146200054e576200057f565b60ff19841687528215158302870194506200057f565b8760005260208060002060005b85811015620005765781548a8201529084019082016200055b565b50505082870194505b50929695505050505050565b60805160a051611b12620005b86000396000818161030f0152610fb7015260006102b60152611b126000f3fe60806040526004361061019c5760003560e01c806370a08231116100ec578063a69df4b51161008a578063bf7e214f11610064578063bf7e214f146104df578063cf309012146104ff578063d505accf14610519578063dd62ed3e1461053957600080fd5b8063a69df4b5146104aa578063a9059cbb146104bf578063b3eac1d8146103e757600080fd5b80638da5cb5b116100c65780638da5cb5b1461041d57806395d89b41146104555780639dc29fac1461046a578063a0712d681461048a57600080fd5b806370a08231146103915780637a9e5e4b146103c75780637ecebe00146103e757600080fd5b806330adf81f116101595780633644e515116101335780633644e515146102fd57806340c10f191461033157806342966c68146103515780636281133d1461037157600080fd5b806330adf81f14610270578063313ce567146102a45780633408e470146102ea57600080fd5b806306fdde03146101a1578063095ea7b3146101cc5780630c53c51c146101fc57806313af40351461020f57806318160ddd1461023157806323b872dd14610250575b600080fd5b3480156101ad57600080fd5b506101b661057f565b6040516101c391906115e0565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611608565b61060d565b60405190151581526020016101c3565b6101b661020a3660046116ed565b6106a0565b34801561021b57600080fd5b5061022f61022a366004611761565b610889565b005b34801561023d57600080fd5b506000545b6040519081526020016101c3565b34801561025c57600080fd5b506101ec61026b36600461177e565b61090c565b34801561027c57600080fd5b506102427f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b3480156102b057600080fd5b506102d87f000000000000000000000000000000000000000000000000000000000000000081565b60405160ff90911681526020016101c3565b3480156102f657600080fd5b5046610242565b34801561030957600080fd5b506102427f000000000000000000000000000000000000000000000000000000000000000081565b34801561033d57600080fd5b5061022f61034c366004611608565b610980565b34801561035d57600080fd5b5061022f61036c3660046117bf565b610a6f565b34801561037d57600080fd5b506101ec61038c3660046117d8565b610a83565b34801561039d57600080fd5b506102426103ac366004611761565b6001600160a01b031660009081526001602052604090205490565b3480156103d357600080fd5b5061022f6103e2366004611761565b610bd7565b3480156103f357600080fd5b50610242610402366004611761565b6001600160a01b031660009081526008602052604090205490565b34801561042957600080fd5b5060045461043d906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b34801561046157600080fd5b506101b6610c48565b34801561047657600080fd5b5061022f610485366004611608565b610c55565b34801561049657600080fd5b5061022f6104a53660046117bf565b610e4c565b3480156104b657600080fd5b5061022f610e84565b3480156104cb57600080fd5b506101ec6104da366004611608565b610eb7565b3480156104eb57600080fd5b5060035461043d906001600160a01b031681565b34801561050b57600080fd5b506007546101ec9060ff1681565b34801561052557600080fd5b5061022f61053436600461185f565b610ed2565b34801561054557600080fd5b506102426105543660046118cd565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b6006805461058c90611906565b80601f01602080910402602001604051908101604052809291908181526020018280546105b890611906565b80156106055780601f106105da57610100808354040283529160200191610605565b820191906000526020600020905b8154815290600101906020018083116105e857829003601f168201915b505050505081565b6000816002600061061c6111c1565b6001600160a01b03908116825260208083019390935260409182016000908120918816808252919093529120919091556106546111c1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161068e91815260200190565b60405180910390a35060015b92915050565b60606106cf866106c5886001600160a01b031660009081526008602052604090205490565b4688888888610a83565b6107325760405162461bcd60e51b815260206004820152602960248201527f6d6574617472616e73616374696f6e2d7369676e65722d7369676e617475726560448201526805adad2e6dac2e8c6d60bb1b60648201526084015b60405180910390fd5b61073b86611264565b600080306001600160a01b0316877f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e88a60405160200161077d93929190611940565b60408051601f198184030181529082905261079791611979565b6000604051808303816000865af19150503d80600081146107d4576040519150601f19603f3d011682016040523d82523d6000602084013e6107d9565b606091505b50915091508161083c5760405162461bcd60e51b815260206004820152602860248201527f636f6c6f6e792d6d65746174782d66756e6374696f6e2d63616c6c2d756e737560448201526718d8d95cdcd99d5b60c21b6064820152608401610729565b7f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b886108666111c1565b8960405161087693929190611995565b60405180910390a1979650505050505050565b6108a66108946111c1565b6000356001600160e01b031916611290565b6108c25760405162461bcd60e51b8152600401610729906119ca565b600480546001600160a01b0319166001600160a01b0383169081179091556040517fce241d7ca1f669fee44b6fc00b8eba2df3bb514eed0f6f668f8f89096e81ed9490600090a250565b60075460009060ff161561096d576109256108946111c1565b61096d5760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b61097884848461136b565b949350505050565b61098b6108946111c1565b6109a75760405162461bcd60e51b8152600401610729906119ca565b6001600160a01b038216600090815260016020526040812080548392906109cf908490611a0e565b92505081905550806000808282546109e79190611a0e565b90915550506040518181526001600160a01b038316907f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968859060200160405180910390a26040518181526001600160a01b038316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b610a80610a7a6111c1565b82610c55565b50565b600080610b0088308989604051602001610aa09493929190611a21565b60408051601f1981840301815282825280516020918201207f19457468657265756d205369676e6564204d6573736167653a0a33320000000084830152603c8085019190915282518085039091018152605c909301909152815191012090565b6040805160008082526020820180845284905260ff87169282019290925260608101889052608081018790529192509060019060a0016020604051602081039080840390855afa158015610b58573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116610bbb5760405162461bcd60e51b815260206004820152601f60248201527f636f6c6f6e792d6d65746174782d696e76616c69642d7369676e6174757265006044820152606401610729565b6001600160a01b038a8116911614915050979650505050505050565b610be26108946111c1565b610bfe5760405162461bcd60e51b8152600401610729906119ca565b600380546001600160a01b0319166001600160a01b0383169081179091556040517f1abebea81bfa2637f28358c371278fb15ede7ea8dd28d2e03b112ff6d936ada490600090a250565b6005805461058c90611906565b610c5d6111c1565b6001600160a01b0316826001600160a01b031614610d5d576001600160a01b03821660009081526002602052604081208291610c976111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020541015610d065760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b03821660009081526002602052604081208291610d286111c1565b6001600160a01b03166001600160a01b031681526020019081526020016000206000828254610d579190611a67565b90915550505b6001600160a01b038216600090815260016020526040902054811115610dc55760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03821660009081526001602052604081208054839290610ded908490611a67565b9250508190555080600080828254610e059190611a67565b90915550506040518181526001600160a01b038316907fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca59060200160405180910390a25050565b610e576108946111c1565b610e735760405162461bcd60e51b8152600401610729906119ca565b610a80610e7e6111c1565b82610980565b610e8f6108946111c1565b610eab5760405162461bcd60e51b8152600401610729906119ca565b6007805460ff19169055565b6000610ecb610ec46111c1565b848461090c565b9392505050565b60075460ff1615610f3057610ee86108946111c1565b610f305760405162461bcd60e51b815260206004820152601960248201527818dbdb1bdb9e4b5d1bdad95b8b5d5b985d5d1a1bdc9a5cd959603a1b6044820152606401610729565b42841015610f805760405162461bcd60e51b815260206004820152601d60248201527f636f6c6f6e792d746f6b656e2d657870697265642d646561646c696e650000006044820152606401610729565b6040805180820182526002815261190160f01b6020808301919091526001600160a01b038a166000908152600890915291822080547f0000000000000000000000000000000000000000000000000000000000000000917f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c9918c918c918c918861100983611a7a565b909155506040805160208101969096526001600160a01b0394851690860152929091166060840152608083015260a082015260c0810188905260e0016040516020818303038152906040528051906020012060405160200161106d93929190611a93565b60408051601f198184030181528282528051602091820120600080855291840180845281905260ff88169284019290925260608301869052608083018590529092509060019060a0016020604051602081039080840390855afa1580156110d8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061110e5750886001600160a01b0316816001600160a01b0316145b61115a5760405162461bcd60e51b815260206004820152601e60248201527f636f6c6f6e792d746f6b656e2d696e76616c69642d7369676e617475726500006044820152606401610729565b6001600160a01b038981166000818152600260209081526040808320948d16808452948252918290208b905590518a81527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050505050505050565b60003633301480156111d4575060348110155b1561125d57600080368080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505082810160131901519091507f02bcc191e283bfba76a1369ec8ba06566f33010645097c104c312753e04935e8811461124c5733935050505090565b5001516001600160a01b0316919050565b3391505090565b6001600160a01b038116600090815260086020526040812080549161128883611a7a565b919050555050565b6000306001600160a01b038416036112aa5750600161069a565b6004546001600160a01b03908116908416036112c85750600161069a565b6003546001600160a01b03166112e05750600061069a565b60035460405163b700961360e01b81526001600160a01b0385811660048301523060248301526001600160e01b0319851660448301529091169063b700961390606401602060405180830381865afa158015611340573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113649190611aba565b905061069a565b60006113756111c1565b6001600160a01b0316846001600160a01b031614611475576001600160a01b038416600090815260026020526040812083916113af6111c1565b6001600160a01b03166001600160a01b0316815260200190815260200160002054101561141e5760405162461bcd60e51b815260206004820152601e60248201527f64732d746f6b656e2d696e73756666696369656e742d617070726f76616c00006044820152606401610729565b6001600160a01b038416600090815260026020526040812083916114406111c1565b6001600160a01b03166001600160a01b03168152602001908152602001600020600082825461146f9190611a67565b90915550505b6001600160a01b0384166000908152600160205260409020548211156114dd5760405162461bcd60e51b815260206004820152601d60248201527f64732d746f6b656e2d696e73756666696369656e742d62616c616e63650000006044820152606401610729565b6001600160a01b03841660009081526001602052604081208054849290611505908490611a67565b90915550506001600160a01b03831660009081526001602052604081208054849290611532908490611a0e565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161157e91815260200190565b60405180910390a35060019392505050565b60005b838110156115ab578181015183820152602001611593565b50506000910152565b600081518084526115cc816020860160208601611590565b601f01601f19169290920160200192915050565b602081526000610ecb60208301846115b4565b6001600160a01b0381168114610a8057600080fd5b6000806040838503121561161b57600080fd5b8235611626816115f3565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600082601f83011261165b57600080fd5b813567ffffffffffffffff8082111561167657611676611634565b604051601f8301601f19908116603f0116810190828211818310171561169e5761169e611634565b816040528381528660208588010111156116b757600080fd5b836020870160208301376000602085830101528094505050505092915050565b803560ff811681146116e857600080fd5b919050565b600080600080600060a0868803121561170557600080fd5b8535611710816115f3565b9450602086013567ffffffffffffffff81111561172c57600080fd5b6117388882890161164a565b9450506040860135925060608601359150611755608087016116d7565b90509295509295909350565b60006020828403121561177357600080fd5b8135610ecb816115f3565b60008060006060848603121561179357600080fd5b833561179e816115f3565b925060208401356117ae816115f3565b929592945050506040919091013590565b6000602082840312156117d157600080fd5b5035919050565b600080600080600080600060e0888a0312156117f357600080fd5b87356117fe816115f3565b96506020880135955060408801359450606088013567ffffffffffffffff81111561182857600080fd5b6118348a828b0161164a565b9450506080880135925060a0880135915061185160c089016116d7565b905092959891949750929550565b600080600080600080600060e0888a03121561187a57600080fd5b8735611885816115f3565b96506020880135611895816115f3565b955060408801359450606088013593506118b1608089016116d7565b925060a0880135915060c0880135905092959891949750929550565b600080604083850312156118e057600080fd5b82356118eb816115f3565b915060208301356118fb816115f3565b809150509250929050565b600181811c9082168061191a57607f821691505b60208210810361193a57634e487b7160e01b600052602260045260246000fd5b50919050565b60008451611952818460208901611590565b919091019283525060601b6bffffffffffffffffffffffff19166020820152603401919050565b6000825161198b818460208701611590565b9190910192915050565b6001600160a01b038481168252831660208201526060604082018190526000906119c1908301846115b4565b95945050505050565b602080825260149082015273191ccb585d5d1a0b5d5b985d5d1a1bdc9a5e995960621b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561069a5761069a6119f8565b8481526bffffffffffffffffffffffff198460601b16602082015282603482015260008251611a57816054850160208701611590565b9190910160540195945050505050565b8181038181111561069a5761069a6119f8565b600060018201611a8c57611a8c6119f8565b5060010190565b60008451611aa5818460208901611590565b91909101928352506020820152604001919050565b600060208284031215611acc57600080fd5b81518015158114610ecb57600080fdfea2646970667358221220b7b9a606b195aca0708557af077c8e46e084718c5656fc19aa4f97b00b0bfb8b64736f6c63430008170033",W1=a=>a.length>1,Ln=class extends gi{constructor(...e){W1(e)?super(...e):super(Ku,Lh,e[0])}deploy(e,t,n,i){return super.deploy(e,t,n,i||{})}getDeployTransaction(e,t,n,i){return super.getDeployTransaction(e,t,n,i||{})}attach(e){return super.attach(e)}connect(e){return super.connect(e)}static createInterface(){return new te.Interface(Ku)}static connect(e,t){return new oe(e,Ku,t)}};xe(Ln,"bytecode",Lh),xe(Ln,"abi",Ku);var Mp=[{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],stateMutability:"nonpayable",type:"constructor"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Approval",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Burn",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"guy",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Mint",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"src",type:"address"},{indexed:!0,internalType:"address",name:"dst",type:"address"},{indexed:!1,internalType:"uint256",name:"wad",type:"uint256"}],name:"Transfer",type:"event"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"guy",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[],name:"locked",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"src",type:"address"},{internalType:"address",name:"dst",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"mint",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"guy",type:"address"},{internalType:"uint256",name:"wad",type:"uint256"}],name:"burn",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlock",outputs:[],stateMutability:"nonpayable",type:"function"}],Ni=class{static createInterface(){return new te.Interface(Mp)}static connect(e,t){return new oe(e,Mp,t)}};xe(Ni,"abi",Mp);var Ip=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"}],name:"ColonyNetworkSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"by",type:"address"},{indexed:!1,internalType:"address",name:"from",type:"address"},{indexed:!1,internalType:"address",name:"to",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"StakeTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!0,internalType:"address",name:"lockedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"lockCount",type:"uint256"}],name:"TokenLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"approvedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeobligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenDeposited",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"obligatedBy",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenObligated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address",name:"recipient",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"lockId",type:"uint256"}],name:"UserTokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"UserTokenWithdrawn",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",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:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetwork",type:"address"}],name:"setColonyNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"lockToken",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_lockId",type:"uint256"}],name:"incrementLockCounterTo",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"depositFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"},{internalType:"bool",name:"_force",type:"bool"}],name:"transfer",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bool",name:"_force",type:"bool"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"withdraw",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getTotalLockCount",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_user",type:"address"}],name:"getUserLock",outputs:[{components:[{internalType:"uint256",name:"lockCount",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"DEPRECATED_timestamp",type:"uint256"},{internalType:"uint256",name:"pendingBalance",type:"uint256"}],internalType:"struct TokenLockingDataTypes.Lock",name:"lock",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"getTotalObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getApproval",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_obligator",type:"address"}],name:"getObligation",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Di=class{static createInterface(){return new te.Interface(Ip)}static connect(e,t){return new oe(e,Ip,t)}};xe(Di,"abi",Ip);var Oi;(function(a){a.TokenClient="TokenClient",a.TokenLockingClient="TokenLockingClient"})(Oi||(Oi={}));var En;(function(a){a.Colony="Colony",a.ColonyLegacy="ColonyLegacy",a.Erc20="Erc20",a.Erc2612="Erc2612",a.Sai="Sai"})(En||(En={}));var{AddressZero:Uh}=xt;async function $1(a){try{await a.authority();return}catch{throw new Error("Token can not be assigned a TokenAuthority")}}var Q1=async(a,e)=>{let t,n=!0,i=!0,r=!0;t=Ln.connect(a,e);try{await t.totalSupply()}catch(s){throw new Error(`Token is probably not a valid ERC20 token, got ${s.message}`)}try{await t.locked(),await $1(t)}catch{n=!1}try{await t.getMetatransactionNonce(Uh)}catch{i=!1}try{await t.nonces(Uh)}catch{r=!1}return n?i?t.tokenClientType=En.Colony:(t=Ni.connect(a,e),t.tokenClientType=En.ColonyLegacy):r?(t=An.connect(a,e),t.tokenClientType=En.Erc2612):(t=kn.connect(a,e),t.tokenClientType=En.Erc20),t.clientType=Oi.TokenClient,t},Cp=Q1;var Y1=(a,e)=>{let t=Di.connect(a,e);return t.clientType=Oi.TokenLockingClient,t},Sp=Y1;var{AddressZero:Rp}=xt,X1=kn.connect(Rp,new ia.BaseProvider(3656691)).interface,Z1=Pi.connect(Rp,new ia.BaseProvider(3656691)).interface,eg=An.connect(Rp,new ia.BaseProvider(3656691)).interface;var Pp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"}],Gs=class{static createInterface(){return new te.Interface(Pp)}static connect(e,t){return new oe(e,Pp,t)}};Gs.abi=Pp;var Np=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"}],Ws=class{static createInterface(){return new te.Interface(Np)}static connect(e,t){return new oe(e,Np,t)}};Ws.abi=Np;var Dp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"auction",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"quantity",type:"uint256"}],name:"AuctionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"colonyId",type:"uint256"},{indexed:!0,internalType:"address",name:"colonyAddress",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"ColonyLabelRegistered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyNetworkInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"version",type:"uint256"},{indexed:!1,internalType:"address",name:"resolver",type:"address"}],name:"ColonyVersionAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionAddedToNetwork",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"ExtensionDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionInstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"}],name:"ExtensionUninstalled",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"bytes32",name:"extensionId",type:"bytes32"},{indexed:!0,internalType:"address",name:"colony",type:"address"},{indexed:!1,internalType:"uint256",name:"version",type:"uint256"}],name:"ExtensionUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"metaColony",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"rootSkillId",type:"uint256"}],name:"MetaColonyCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miningCycleResolver",type:"address"}],name:"MiningCycleResolverSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"feeInverse",type:"uint256"}],name:"NetworkFeeInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"ens",type:"address"},{indexed:!1,internalType:"bytes32",name:"rootNode",type:"bytes32"}],name:"RegistrarInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"miner",type:"address"},{indexed:!1,internalType:"uint256",name:"tokensLost",type:"uint256"}],name:"ReputationMinerPenalised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"hash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"nLeaves",type:"uint256"}],name:"ReputationMiningCycleComplete",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"inactiveReputationMiningCycle",type:"address"}],name:"ReputationMiningInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ReputationMiningRewardSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"bytes32",name:"newHash",type:"bytes32"},{indexed:!1,internalType:"uint256",name:"newNLeaves",type:"uint256"},{indexed:!1,internalType:"address[]",name:"stakers",type:"address[]"},{indexed:!1,internalType:"uint256",name:"reward",type:"uint256"}],name:"ReputationRootHashSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"parentSkillId",type:"uint256"}],name:"SkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAuthorityAddress",type:"address"}],name:"TokenAuthorityDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenAddress",type:"address"}],name:"TokenDeployed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"tokenLocking",type:"address"}],name:"TokenLockingAddressSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"bool",name:"status",type:"bool"}],name:"TokenWhitelisted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bytes32",name:"label",type:"bytes32"}],name:"UserLabelRegistered",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_interfaceID",type:"bytes4"}],name:"supportsInterface",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_colony",type:"address"},{internalType:"uint128",name:"_nUpdates",type:"uint128"},{internalType:"uint128",name:"_nPreviousUpdates",type:"uint128"}],name:"setReplacementReputationUpdateLogEntry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"getReplacementReputationUpdateLogEntry",outputs:[{components:[{internalType:"address",name:"user",type:"address"},{internalType:"int256",name:"amount",type:"int256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"address",name:"colony",type:"address"},{internalType:"uint128",name:"nUpdates",type:"uint128"},{internalType:"uint128",name:"nPreviousUpdates",type:"uint128"}],internalType:"struct ColonyNetworkDataTypes.ReputationLogEntry",name:"_reputationLogEntry",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_reputationMiningCycle",type:"address"}],name:"getReplacementReputationUpdateLogsExist",outputs:[{internalType:"bool",name:"_exists",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMetaColony",outputs:[{internalType:"address payable",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColonyCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"isColony",outputs:[{internalType:"bool",name:"_addressIsColony",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],name:"addSkill",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"getSkill",outputs:[{components:[{internalType:"uint128",name:"nParents",type:"uint128"},{internalType:"uint128",name:"nChildren",type:"uint128"},{internalType:"uint256[]",name:"parents",type:"uint256[]"},{internalType:"uint256[]",name:"children",type:"uint256[]"},{internalType:"bool",name:"DEPRECATED_globalSkill",type:"bool"},{internalType:"bool",name:"deprecated",type:"bool"}],internalType:"struct ColonyNetworkDataTypes.Skill",name:"_skill",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"deprecateSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateSkill",outputs:[{internalType:"bool",name:"_changed",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[{internalType:"uint256",name:"_rootLocalSkillId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"appendReputationUpdateLog",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getSkillCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationMiningSkillId",outputs:[{internalType:"uint256",name:"_skillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenLockingAddress",type:"address"}],name:"setTokenLocking",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTokenLocking",outputs:[{internalType:"address",name:"_lockingAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createMetaColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"},{internalType:"bool",name:"_useExtensionManager",type:"bool"}],name:"createColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_tokenAddress",type:"address"},{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"},{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_metadata",type:"string"}],name:"createColonyForFrontend",outputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"colony",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"},{internalType:"address",name:"_resolver",type:"address"}],name:"addColonyVersion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_resolver",type:"address"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getColony",outputs:[{internalType:"address",name:"_colonyAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentColonyVersion",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_parentSkillIndex",type:"uint256"}],name:"getParentSkillId",outputs:[{internalType:"uint256",name:"_parentSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"getChildSkillId",outputs:[{internalType:"uint256",name:"_childSkillId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bool",name:"_active",type:"bool"}],name:"getReputationMiningCycle",outputs:[{internalType:"address",name:"_repMiningCycleAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_timeStaked",type:"uint256"},{internalType:"uint256",name:"_submissonIndex",type:"uint256"}],name:"calculateMinerWeight",outputs:[{internalType:"uint256",name:"_minerWeight",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_version",type:"uint256"}],name:"getColonyVersionResolver",outputs:[{internalType:"address",name:"_resolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_newHash",type:"bytes32"},{internalType:"uint256",name:"_newNLeaves",type:"uint256"},{internalType:"address[]",name:"_stakers",type:"address[]"}],name:"setReputationRootHash",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"startNextCycle",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseReputationMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationRootHash",outputs:[{internalType:"bytes32",name:"rootHash",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNLeaves",outputs:[{internalType:"uint256",name:"nLeaves",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getReputationRootHashNNodes",outputs:[{internalType:"uint256",name:"nNodes",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"startTokenAuction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_ens",type:"address"},{internalType:"bytes32",name:"_rootNode",type:"bytes32"}],name:"setupRegistrar",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_username",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerUserLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_colonyName",type:"string"},{internalType:"string",name:"_orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_orbitdb",type:"string"}],name:"updateUserOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"getProfileDBAddress",outputs:[{internalType:"string",name:"_orbitdb",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_addr",type:"address"}],name:"lookupRegisteredENSDomain",outputs:[{internalType:"string",name:"_domain",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_node",type:"bytes32"}],name:"addr",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getENSRegistrar",outputs:[{internalType:"address",name:"_address",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_miningResolverAddress",type:"address"}],name:"setMiningResolver",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getMiningResolver",outputs:[{internalType:"address",name:"miningResolverAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_resolver",type:"address"}],name:"addExtensionToNetwork",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"uint256",name:"_version",type:"uint256"}],name:"getExtensionResolver",outputs:[{internalType:"address",name:"_resolver",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_extensionId",type:"bytes32"},{internalType:"address",name:"_colony",type:"address"}],name:"getExtensionInstallation",outputs:[{internalType:"address",name:"_installation",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFeeInverse",outputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_feeInverse",type:"uint256"}],name:"setFeeInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getPayoutWhitelist",outputs:[{internalType:"bool",name:"_status",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bool",name:"_status",type:"bool"}],name:"setPayoutWhitelist",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_stakers",type:"address[]"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"punishStakers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"stakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"unstakeForMining",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"getMiningStake",outputs:[{components:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"timestamp",type:"uint256"}],internalType:"struct ColonyNetworkDataTypes.MiningStake",name:"_info",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"reward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"burnUnneededRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_recipient",type:"address"}],name:"claimMiningReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setReputationMiningCycleReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getReputationMiningCycleReward",outputs:[{internalType:"uint256",name:"_amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"string",name:"_name",type:"string"},{internalType:"string",name:"_symbol",type:"string"},{internalType:"uint8",name:"_decimals",type:"uint8"}],name:"deployTokenViaNetwork",outputs:[{internalType:"address",name:"_token",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"address",name:"_colony",type:"address"},{internalType:"address[]",name:"_allowedToTransfer",type:"address[]"}],name:"deployTokenAuthority",outputs:[{internalType:"address",name:"_tokenAuthority",type:"address"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"},{internalType:"bool",name:"_allowed",type:"bool"}],name:"setMiningDelegate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_delegate",type:"address"}],name:"getMiningDelegator",outputs:[{internalType:"address",name:"_delegator",type:"address"}],stateMutability:"view",type:"function"}],Bi=class{static createInterface(){return new te.Interface(Dp)}static connect(e,t){return new oe(e,Dp,t)}};Bi.abi=Dp;var ka=class{constructor({colonyNetwork:e,contract:t,method:n,args:i,eventData:r,txConfig:s}){this.colonyNetwork=e,this.contract=t,this.method=n,this.args=i,this.eventData=r,this.txConfig=s}async getArgs(){let e=[];return typeof this.args=="function"?e=await this.args():e=this.args,e}async getTx(){let e=await this.getArgs();return await this.contract.functions[this.method].apply(this.contract,e)}async getMined(e){let t=await e.wait();return this.getEventData(t)}async getEventData(e){if(this.eventData){let t=await this.eventData(e);if(this.txConfig?.metadataType&&t.metadata){let n=this.colonyNetwork.ipfs.getMetadataForEvent.bind(this.colonyNetwork.ipfs,zs[this.txConfig.metadataType],t.metadata);return[t,e,n]}return[t,e]}return[{},e]}async broadcastMetaTx(e){let t=this.colonyNetwork.getSigner(),{provider:n}=t;if(!n)throw new Error("No provider found");let r=await(await fetch(`${this.colonyNetwork.config.metaTxBroadcasterEndpoint}/broadcast`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).json();if(r.status!=="success")throw new Error(`Could not send Metatransaction. Reason given: ${r.data.reason}`);if(!r.data?.txHash)throw new Error("Could not get transaction hash from broadcaster response");return n.getTransaction(r.data.txHash)}async waitForMetaTx(e){let t=await e.wait();return t.parsedLogs=Jl(t.logs,this.contract.interface),t}tx(){return{send:async()=>{let e=await this.getTx();return[e,this.getMined.bind(this,e)]},mined:async()=>{let e=await this.getTx();return this.getMined(e)},encode:async()=>{let e=await this.getArgs();return this.contract.interface.encodeFunctionData(this.method,e)}}}};var{arrayify:ng,solidityKeccak256:ag,splitSignature:ig}=te,Fi=class extends ka{async sendMetaTransaction(e,t){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let n=this.colonyNetwork.getSigner(),{provider:i}=n;if(!i)throw new Error("No provider found");let r;this.colonyNetwork.network===Fn.Custom?r=1:r=(await i.getNetwork()).chainId;let s=await n.getAddress(),o=await this.contract.functions.getMetatransactionNonce(s),l=ag(["uint256","address","uint256","bytes"],[o.toString(),t,r,e]),p=ng(l),c=await n.signMessage(p),{r:x,s:C,v:_}=ig(c),v={target:t,payload:e,userAddress:s,r:x,s:C,v:_};return this.broadcastMetaTx(v)}async getMetaTx(){let e=await this.getArgs(),t=this.contract.interface.encodeFunctionData(this.method,e);return this.sendMetaTransaction(t,this.contract.address)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}metaTx(){return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var ne=(a,e)=>{if("events"in e&&e.events){let t=e.events.find(n=>n.event===a);if(t?.args)return t.args}else if("parsedLogs"in e&&e.parsedLogs){let t=e.parsedLogs.find(n=>n.name===a);if(t?.args)return t.args}},Ju=(a,e,t)=>{let n;"events"in e&&e.events?n=e.events:"logs"in e&&e.logs?n=e.logs:n=[];for(let i=0;i{let n=await this.getMotionTx(t);return[n,this.getMotionMined.bind(this,n)]},mined:async()=>{let n=await this.getMotionTx(t);return this.getMotionMined(n)},encode:async()=>{let[n]=await this.getEncodedMotionTx(t);return n}}}metaMotion(t=ke.RootDomain){return{send:async()=>{let n=await this.getMetaMotionTx(t);return[n,this.getMetaMotionMinded.bind(this,n)]},mined:async()=>{let n=await this.getMetaMotionTx(t);return this.getMetaMotionMinded(n)}}}};var Op=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Li=class{static createInterface(){return new te.Interface(Op)}static connect(e,t){return new oe(e,Op,t)}};Li.abi=Op;var Bp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Ui=class{static createInterface(){return new te.Interface(Bp)}static connect(e,t){return new oe(e,Bp,t)}};Ui.abi=Bp;var Fp=[{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"bytes32",name:"txHash",type:"bytes32"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"Annotation",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"},{indexed:!1,internalType:"int256",name:"amount",type:"int256"}],name:"ArbitraryReputationUpdate",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"target",type:"address"},{indexed:!1,internalType:"bytes",name:"data",type:"bytes"},{indexed:!1,internalType:"bool",name:"success",type:"bool"}],name:"ArbitraryTransaction",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address[]",name:"users",type:"address[]"},{indexed:!1,internalType:"int256[]",name:"amounts",type:"int256[]"}],name:"ColonyBootstrapped",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"payoutRemainder",type:"uint256"}],name:"ColonyFundsClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fromPot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"toPot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyFundsMovedBetweenFundingPots",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"colonyNetwork",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"}],name:"ColonyInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ColonyMetadataDelta",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardInverse",type:"uint256"}],name:"ColonyRewardInverseSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint8",name:"role",type:"uint8"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"ColonyRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"oldVersion",type:"uint256"},{indexed:!1,internalType:"uint256",name:"newVersion",type:"uint256"}],name:"ColonyUpgraded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"domainId",type:"uint256"}],name:"DomainAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"DomainDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"DomainMetadata",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureCancelled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"uint256",name:"claimDelay",type:"uint256"}],name:"ExpenditureClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],name:"ExpenditureGlobalClaimDelaySet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"}],name:"ExpenditureLocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!1,internalType:"string",name:"metadata",type:"string"}],name:"ExpenditureMetadataSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"int256",name:"payoutModifier",type:"int256"}],name:"ExpenditurePayoutModifierSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"ExpenditurePayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"address",name:"recipient",type:"address"}],name:"ExpenditureRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"ExpenditureSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"storageSlot",type:"uint256"},{indexed:!1,internalType:"bool[]",name:"mask",type:"bool[]"},{indexed:!1,internalType:"bytes32[]",name:"keys",type:"bytes32[]"},{indexed:!1,internalType:"bytes32",name:"value",type:"bytes32"}],name:"ExpenditureStateChanged",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"expenditureId",type:"uint256"},{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"ExpenditureTransferred",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"fundingPotId",type:"uint256"}],name:"FundingPotAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"}],name:"LocalSkillAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"localSkillId",type:"uint256"},{indexed:!1,internalType:"bool",name:"deprecated",type:"bool"}],name:"LocalSkillDeprecated",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"}],name:"PaymentFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PaymentPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"address",name:"recipient",type:"address"}],name:"PaymentRecipientSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"paymentId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"skillId",type:"uint256"}],name:"PaymentSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"fundingPotId",type:"uint256"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"PayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeEntered",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExitApproved",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"}],name:"RecoveryModeExited",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"bool",name:"setTo",type:"bool"}],name:"RecoveryRoleSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"slot",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"fromValue",type:"bytes32"},{indexed:!1,internalType:"bytes32",name:"toValue",type:"bytes32"}],name:"RecoveryStorageSlotSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"},{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"uint256",name:"fee",type:"uint256"},{indexed:!1,internalType:"uint256",name:"rewardRemainder",type:"uint256"}],name:"RewardPayoutClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleEnded",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"rewardPayoutId",type:"uint256"}],name:"RewardPayoutCycleStarted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskAdded",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"specificationHash",type:"bytes32"}],name:"TaskBriefSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCanceled",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address[]",name:"reviewerAddresses",type:"address[]"}],name:"TaskChangedViaSignatures",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskCompleted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"bytes32",name:"deliverableHash",type:"bytes32"}],name:"TaskDeliverableSubmitted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"dueDate",type:"uint256"}],name:"TaskDueDateSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"}],name:"TaskFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TaskPayoutSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!0,internalType:"address",name:"user",type:"address"}],name:"TaskRoleUserSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"skillId",type:"uint256"}],name:"TaskSkillSet",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!0,internalType:"uint256",name:"taskId",type:"uint256"},{indexed:!1,internalType:"enum ColonyDataTypes.TaskRole",name:"role",type:"uint8"},{indexed:!1,internalType:"uint8",name:"rating",type:"uint8"}],name:"TaskWorkRatingRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"}],name:"TokenUnlocked",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"token",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensBurned",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"address",name:"who",type:"address"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"TokensMinted",type:"event"},{inputs:[],name:"approveExitRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"}],name:"checkNotAdditionalProtectedVariable",outputs:[],stateMutability:"view",type:"function"},{inputs:[],name:"enterRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"exitRecoveryMode",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"isInRecoveryMode",outputs:[{internalType:"bool",name:"inRecoveryMode",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"numRecoveryRoles",outputs:[{internalType:"uint64",name:"numRoles",type:"uint64"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"removeRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"setRecoveryRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setStorageSlotRecovery",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"authority",outputs:[{internalType:"address",name:"colonyAuthority",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"colonyOwner",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"colonyVersion",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_newVersion",type:"uint256"}],name:"upgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getColonyNetwork",outputs:[{internalType:"address",name:"colonyNetwork",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getToken",outputs:[{internalType:"address",name:"tokenAddress",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_targets",type:"address[]"},{internalType:"bytes[]",name:"_actions",type:"bytes[]"},{internalType:"bool",name:"_strict",type:"bool"}],name:"makeArbitraryTransactions",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_target",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"}],name:"makeSingleArbitraryTransaction",outputs:[{internalType:"bool",name:"success",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_txHash",type:"bytes32"},{internalType:"string",name:"_metadata",type:"string"}],name:"annotateTransaction",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setRootRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArbitrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setArchitectureRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setFundingRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_setTo",type:"bool"}],name:"setAdministrationRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bytes32",name:"_roles",type:"bytes32"}],name:"setUserRoles",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"}],name:"hasUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"enum ColonyDataTypes.ColonyRole",name:"_role",type:"uint8"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"hasInheritedUserRole",outputs:[{internalType:"bool",name:"hasRole",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_childDomainId",type:"uint256"}],name:"userCanSetRoles",outputs:[{internalType:"bool",name:"canSet",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domain",type:"uint256"}],name:"getUserRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitDomainReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"address",name:"_user",type:"address"},{internalType:"int256",name:"_amount",type:"int256"}],name:"emitSkillReputationPenalty",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_colonyNetworkAddress",type:"address"},{internalType:"address",name:"_token",type:"address"}],name:"initialiseColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadata",type:"string"}],name:"editColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"_metadataDelta",type:"string"}],name:"editColonyByDelta",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address[]",name:"_users",type:"address[]"},{internalType:"int256[]",name:"_amount",type:"int256[]"}],name:"bootstrapColony",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_guy",type:"address"},{internalType:"uint256",name:"_wad",type:"uint256"}],name:"mintTokensFor",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"lockToken",outputs:[{internalType:"uint256",name:"timesLocked",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"},{internalType:"uint256",name:"lockId",type:"uint256"}],name:"unlockTokenForUser",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"colonyName",type:"string"},{internalType:"string",name:"orbitdb",type:"string"}],name:"registerColonyLabel",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"string",name:"orbitdb",type:"string"}],name:"updateColonyOrbitDB",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"version",type:"uint256"}],name:"installExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"uint256",name:"newVersion",type:"uint256"}],name:"upgradeExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"extensionId",type:"bytes32"}],name:"uninstallExtension",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"initialiseRootLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"addLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"localSkillId",type:"uint256"},{internalType:"bool",name:"deprecated",type:"bool"}],name:"deprecateLocalSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRootLocalSkill",outputs:[{internalType:"uint256",name:"rootLocalSkill",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_parentDomainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"addDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"editDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecateDomain",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getDomain",outputs:[{components:[{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"}],internalType:"struct ColonyDataTypes.Domain",name:"domain",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDomainCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"verifyReputationProof",outputs:[{internalType:"bool",name:"isValid",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_globalClaimDelay",type:"uint256"}],name:"setDefaultGlobalClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"makeExpenditure",outputs:[{internalType:"uint256",name:"expenditureId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_newOwner",type:"address"}],name:"transferExpenditureViaArbitration",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"lockExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeExpenditure",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"string",name:"_metadata",type:"string"}],name:"setExpenditureMetadata",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setExpenditureRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"}],name:"setExpenditureRecipients",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"}],name:"setExpenditurePayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setExpenditureSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"}],name:"setExpenditureSkills",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"uint256",name:"_claimDelay",type:"uint256"}],name:"setExpenditureClaimDelay",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"}],name:"setExpenditureClaimDelays",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_slots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"}],name:"setExpenditurePayoutModifiers",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256[]",name:"_recipientSlots",type:"uint256[]"},{internalType:"address payable[]",name:"_recipients",type:"address[]"},{internalType:"uint256[]",name:"_skillIdSlots",type:"uint256[]"},{internalType:"uint256[]",name:"_skillIds",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelaySlots",type:"uint256[]"},{internalType:"uint256[]",name:"_claimDelays",type:"uint256[]"},{internalType:"uint256[]",name:"_payoutModifierSlots",type:"uint256[]"},{internalType:"int256[]",name:"_payoutModifiers",type:"int256[]"},{internalType:"address[]",name:"_payoutTokens",type:"address[]"},{internalType:"uint256[][]",name:"_payoutSlots",type:"uint256[][]"},{internalType:"uint256[][]",name:"_payoutValues",type:"uint256[][]"}],name:"setExpenditureValues",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_storageSlot",type:"uint256"},{internalType:"bool[]",name:"_mask",type:"bool[]"},{internalType:"bytes32[]",name:"_keys",type:"bytes32[]"},{internalType:"bytes32",name:"_value",type:"bytes32"}],name:"setExpenditureState",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimExpenditurePayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getExpenditureCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getExpenditure",outputs:[{components:[{internalType:"enum ColonyDataTypes.ExpenditureStatus",name:"status",type:"uint8"},{internalType:"address",name:"owner",type:"address"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"finalizedTimestamp",type:"uint256"},{internalType:"uint256",name:"globalClaimDelay",type:"uint256"}],internalType:"struct ColonyDataTypes.Expenditure",name:"expenditure",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"}],name:"getExpenditureSlot",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"uint256",name:"claimDelay",type:"uint256"},{internalType:"int256",name:"payoutModifier",type:"int256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.ExpenditureSlot",name:"expenditureSlot",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_slot",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getExpenditureSlotPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"addPayment",outputs:[{internalType:"uint256",name:"paymentId",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_recipient",type:"address"}],name:"setPaymentRecipient",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setPaymentSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setPaymentPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getPayment",outputs:[{components:[{internalType:"address payable",name:"recipient",type:"address"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skills",type:"uint256[]"}],internalType:"struct ColonyDataTypes.Payment",name:"payment",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"claimPayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getPaymentCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"makeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTaskCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskChangeNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskChange",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint8[]",name:"_sigV",type:"uint8[]"},{internalType:"bytes32[]",name:"_sigR",type:"bytes32[]"},{internalType:"bytes32[]",name:"_sigS",type:"bytes32[]"},{internalType:"uint8[]",name:"_mode",type:"uint8[]"},{internalType:"uint256",name:"_value",type:"uint256"},{internalType:"bytes",name:"_data",type:"bytes"}],name:"executeTaskRoleAssignment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"uint8",name:"_rating",type:"uint8"},{internalType:"bytes32",name:"_salt",type:"bytes32"}],name:"revealTaskWorkRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"generateSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTaskWorkRatingSecretsInfo",outputs:[{internalType:"uint256",name:"nSecrets",type:"uint256"},{internalType:"uint256",name:"lastSubmittedAt",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskWorkRatingSecret",outputs:[{internalType:"bytes32",name:"secret",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"}],name:"setTaskManagerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address payable",name:"_user",type:"address"}],name:"setTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskEvaluatorRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"removeTaskWorkerRole",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"setTaskSkill",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_specificationHash",type:"bytes32"}],name:"setTaskBrief",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint256",name:"_dueDate",type:"uint256"}],name:"setTaskDueDate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"}],name:"submitTaskDeliverable",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"bytes32",name:"_deliverableHash",type:"bytes32"},{internalType:"bytes32",name:"_ratingSecret",type:"bytes32"}],name:"submitTaskDeliverableAndRating",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"finalizeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"cancelTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"completeTask",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getTask",outputs:[{internalType:"bytes32",name:"specificationHash",type:"bytes32"},{internalType:"bytes32",name:"deliverableHash",type:"bytes32"},{internalType:"enum ColonyDataTypes.TaskStatus",name:"status",type:"uint8"},{internalType:"uint256",name:"dueDate",type:"uint256"},{internalType:"uint256",name:"fundingPotId",type:"uint256"},{internalType:"uint256",name:"completionTimestamp",type:"uint256"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256[]",name:"skillIds",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"}],name:"getTaskRole",outputs:[{components:[{internalType:"address payable",name:"user",type:"address"},{internalType:"bool",name:"rateFail",type:"bool"},{internalType:"enum ColonyDataTypes.TaskRatings",name:"rating",type:"uint8"}],internalType:"struct ColonyDataTypes.Role",name:"role",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rewardInverse",type:"uint256"}],name:"setRewardInverse",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getRewardInverse",outputs:[{internalType:"uint256",name:"rewardInverse",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"getTaskPayout",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskManagerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskEvaluatorPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"setTaskWorkerPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"address",name:"_token",type:"address"},{internalType:"uint256",name:"_managerAmount",type:"uint256"},{internalType:"uint256",name:"_evaluatorAmount",type:"uint256"},{internalType:"uint256",name:"_workerAmount",type:"uint256"}],name:"setAllTaskPayouts",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"},{internalType:"uint8",name:"_role",type:"uint8"},{internalType:"address",name:"_token",type:"address"}],name:"claimTaskPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"startNextRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"},{internalType:"uint256[7]",name:"_squareRoots",type:"uint256[7]"},{internalType:"bytes",name:"key",type:"bytes"},{internalType:"bytes",name:"value",type:"bytes"},{internalType:"uint256",name:"branchMask",type:"uint256"},{internalType:"bytes32[]",name:"siblings",type:"bytes32[]"}],name:"claimRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"getRewardPayoutInfo",outputs:[{components:[{internalType:"bytes32",name:"reputationState",type:"bytes32"},{internalType:"uint256",name:"colonyWideReputation",type:"uint256"},{internalType:"uint256",name:"totalTokens",type:"uint256"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"tokenAddress",type:"address"},{internalType:"uint256",name:"blockTimestamp",type:"uint256"},{internalType:"uint256",name:"amountRemaining",type:"uint256"},{internalType:"bool",name:"finalized",type:"bool"}],internalType:"struct ColonyDataTypes.RewardPayoutCycle",name:"rewardPayoutCycle",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_payoutId",type:"uint256"}],name:"finalizeRewardPayout",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_id",type:"uint256"}],name:"getFundingPot",outputs:[{internalType:"enum ColonyDataTypes.FundingPotAssociatedType",name:"associatedType",type:"uint8"},{internalType:"uint256",name:"associatedTypeId",type:"uint256"},{internalType:"uint256",name:"payoutsWeCannotMake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getFundingPotCount",outputs:[{internalType:"uint256",name:"count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotBalance",outputs:[{internalType:"uint256",name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_potId",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"getFundingPotPayout",outputs:[{internalType:"uint256",name:"payout",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_fromChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_toChildSkillIndex",type:"uint256"},{internalType:"uint256",name:"_fromPot",type:"uint256"},{internalType:"uint256",name:"_toPot",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_token",type:"address"}],name:"moveFundsBetweenPots",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"claimColonyFunds",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_token",type:"address"}],name:"getNonRewardPotsTotal",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_approvee",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"approveStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"obligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deobligateStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"address",name:"_user",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"address",name:"_recipient",type:"address"}],name:"transferStake",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getApproval",outputs:[{internalType:"uint256",name:"approval",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"address",name:"_obligator",type:"address"},{internalType:"uint256",name:"_domainId",type:"uint256"}],name:"getObligation",outputs:[{internalType:"uint256",name:"obligation",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_fundingPotId",type:"uint256"}],name:"getDomainFromFundingPot",outputs:[{internalType:"uint256",name:"domainId",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"burnTokens",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"unlockToken",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"updateApprovalAmount",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"getTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"}],name:"getTotalTokenApproval",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"}],Vi=class{static createInterface(){return new te.Interface(Fp)}static connect(e,t){return new oe(e,Fp,t)}};Vi.abi=Fp;var Lp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],ji=class{static createInterface(){return new te.Interface(Lp)}static connect(e,t){return new oe(e,Lp,t)}};ji.abi=Lp;var Up=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],Hi=class{static createInterface(){return new te.Interface(Up)}static connect(e,t){return new oe(e,Up,t)}};Hi.abi=Up;var Vp=[{anonymous:!1,inputs:[],name:"ExtensionInitialised",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"authority",type:"address"}],name:"LogSetAuthority",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"address",name:"owner",type:"address"}],name:"LogSetOwner",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"user",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"functionSignature",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"agent",type:"address"},{indexed:!1,internalType:"uint256",name:"fundamentalId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"nPayouts",type:"uint256"}],name:"OneTxPaymentMade",type:"event"},{inputs:[],name:"authority",outputs:[{internalType:"contract DSAuthority",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"getChainId",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes[]",name:"data",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"owner",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"contract DSAuthority",name:"authority_",type:"address"}],name:"setAuthority",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"owner_",type:"address"}],name:"setOwner",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_owner",type:"address"},{internalType:"uint256",name:"_nonce",type:"uint256"},{internalType:"uint256",name:"_chainId",type:"uint256"},{internalType:"bytes",name:"_payload",type:"bytes"},{internalType:"bytes32",name:"_sigR",type:"bytes32"},{internalType:"bytes32",name:"_sigS",type:"bytes32"},{internalType:"uint8",name:"_sigV",type:"uint8"}],name:"verify",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"_identifier",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"_version",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"_roles",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePayment",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_callerPermissionDomainId",type:"uint256"},{internalType:"uint256",name:"_callerChildSkillIndex",type:"uint256"},{internalType:"address payable[]",name:"_workers",type:"address[]"},{internalType:"address[]",name:"_tokens",type:"address[]"},{internalType:"uint256[]",name:"_amounts",type:"uint256[]"},{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_skillId",type:"uint256"}],name:"makePaymentFundedFromDomain",outputs:[],stateMutability:"nonpayable",type:"function"}],qi=class{static createInterface(){return new te.Interface(Vp)}static connect(e,t){return new oe(e,Vp,t)}};qi.abi=Vp;var{AddressZero:pg}=xt,Un=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(ja(Un.extensionType),e.address);if(t===pg)throw new Error(`${Un.extensionType} extension is not installed for this Colony`);let n=await Or(t,e.colonyNetwork.signerOrProvider);if(!Ha(Un.extensionType,n,e.version))throw new Error(`Version ${n} of the ${Un.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=Un.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${Un.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new Un(e,r,n)}static getLatestSupportedVersion(){return Un.supportedVersions[Un.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.oneTxPaymentContract=t,this.version=n}getInternalVotingReputationContract(){return this.oneTxPaymentContract}pay(e,t,n,i){let r=[].concat(e),s=n||ke.RootDomain,o=i?[].concat(i):Array(r.length).fill(this.colony.token.address),l=[].concat(t);if(r.length!==l.length)throw new Error("recipient and amount arrays need to have the same size");if(o.length!==l.length)throw new Error("amount and tokenAddress arrays need to have the same size");let p=Array.from(r.keys());p.sort((_,v)=>r[_].localeCompare(r[v]));let c=p.map(_=>r[_]),x=p.map(_=>l[_]),C=p.map(_=>o[_]);return this.colony.createColonyTxCreator(this.oneTxPaymentContract,"makePaymentFundedFromDomain",async()=>{let[_,v]=await ra(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[wt.Administration,wt.Funding],this.oneTxPaymentContract.address),[S,L]=await ra(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),s,[wt.Administration,wt.Funding]);return[_,v,S,L,c,C,x,s,ke.SkillIgnore]},async _=>({...ne("OneTxPaymentMade",_)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[ja(we.OneTxPayment),t],async n=>({...ne("ExtensionUpgraded",n)}))}},Ga=Un;Ga.supportedVersions=[{version:3,factory:ji},{version:4,factory:Hi},{version:5,factory:qi}],Ga.extensionType=we.OneTxPayment;var Vn=class{constructor(e,t){typeof t=="string"?this.tokenClient=kn.connect(t,e.signerOrProvider):this.tokenClient=t,this.address=this.tokenClient.address,this.colonyNetwork=e}getInternalTokenClient(){return this.tokenClient}async name(){return this.tokenClient.name()}async symbol(){return this.tokenClient.symbol()}async decimals(){return this.tokenClient.decimals()}async totalSupply(){return this.tokenClient.totalSupply()}async balanceOf(e){return this.tokenClient.balanceOf(e)}async allowance(e,t){return this.tokenClient.allowance(e,t)}transfer(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"transfer",[e,t],async n=>({...ne("Transfer",n)}))}transferFrom(e,t,n){return this.colonyNetwork.createTxCreator(this.tokenClient,"transferFrom",[e,t,n],async i=>({...ne("Transfer",i)}))}approve(e,t){return this.colonyNetwork.createTxCreator(this.tokenClient,"approve",async()=>{let n=await this.colonyNetwork.getTokenLocking();return[t||n.address,e]},async n=>({...ne("Approval",n)}))}};var Ks=class extends Vn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=Ln.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}setAuthority(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setAuthority",[t],async n=>({...ne("LogSetAuthority",n)}))}setOwner(t){return this.colonyNetwork.createMetaTxCreator(this.tokenClient,"setOwner",[t],async n=>({...ne("LogSetOwner",n)}))}};var Js=class extends Vn{constructor(t,n){super(t,n);typeof n=="string"?this.tokenClient=An.connect(n,t.signerOrProvider):this.tokenClient=n,this.address=this.tokenClient.address,this.colonyNetwork=t}getInternalTokenClient(){return this.tokenClient}permit(t,n){return this.colonyNetwork.createEip2612TxCreator(this.tokenClient,"permit",async()=>{let i=await this.colonyNetwork.getTokenLocking();return[n||i.address,t]},async i=>({...ne("Approval",i)}))}};var Vh=async(a,e)=>{let t=await Cp(e,a.signerOrProvider);switch(t.tokenClientType){case En.Colony:return new Ks(a,t);case En.Erc20:return new Vn(a,t);case En.Erc2612:return new Js(a,t);default:throw new Error("Your token is not supported in Colony SDK (yet).")}};var jp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createRootMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createDomainMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],zi=class{static createInterface(){return new te.Interface(jp)}static connect(e,t){return new oe(e,jp,t)}};zi.abi=jp;var Hp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Gi=class{static createInterface(){return new te.Interface(Hp)}static connect(e,t){return new oe(e,Hp,t)}};Gi.abi=Hp;var qp=[{anonymous:!1,inputs:[{indexed:!1,internalType:"address",name:"userAddress",type:"address"},{indexed:!1,internalType:"address payable",name:"relayerAddress",type:"address"},{indexed:!1,internalType:"bytes",name:"payload",type:"bytes"}],name:"MetaTransactionExecuted",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"creator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"}],name:"MotionCreated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"address",name:"escalator",type:"address"},{indexed:!0,internalType:"uint256",name:"domainId",type:"uint256"},{indexed:!0,internalType:"uint256",name:"newDomainId",type:"uint256"}],name:"MotionEscalated",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"uint256",name:"eventIndex",type:"uint256"}],name:"MotionEventSet",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!1,internalType:"bytes",name:"action",type:"bytes"},{indexed:!1,internalType:"bool",name:"executed",type:"bool"}],name:"MotionFinalized",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionRewardClaimed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"staker",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"},{indexed:!1,internalType:"uint256",name:"amount",type:"uint256"}],name:"MotionStaked",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"},{indexed:!0,internalType:"uint256",name:"vote",type:"uint256"}],name:"MotionVoteRevealed",type:"event"},{anonymous:!1,inputs:[{indexed:!0,internalType:"uint256",name:"motionId",type:"uint256"},{indexed:!0,internalType:"address",name:"voter",type:"address"}],name:"MotionVoteSubmitted",type:"event"},{inputs:[{internalType:"bool",name:"_deprecated",type:"bool"}],name:"deprecate",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"},{internalType:"bytes",name:"payload",type:"bytes"},{internalType:"bytes32",name:"sigR",type:"bytes32"},{internalType:"bytes32",name:"sigS",type:"bytes32"},{internalType:"uint8",name:"sigV",type:"uint8"}],name:"executeMetaTransaction",outputs:[{internalType:"bytes",name:"",type:"bytes"}],stateMutability:"payable",type:"function"},{inputs:[],name:"finishUpgrade",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes4",name:"_sig",type:"bytes4"}],name:"getCapabilityRoles",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"getColony",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"getDeprecated",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"userAddress",type:"address"}],name:"getMetatransactionNonce",outputs:[{internalType:"uint256",name:"nonce",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"identifier",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"address",name:"_colony",type:"address"}],name:"install",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"bytes[]",name:"",type:"bytes[]"}],name:"multicall",outputs:[{internalType:"bytes[]",name:"results",type:"bytes[]"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"uninstall",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"version",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"pure",type:"function"},{inputs:[{internalType:"uint256",name:"_totalStakeFraction",type:"uint256"},{internalType:"uint256",name:"_voterRewardFraction",type:"uint256"},{internalType:"uint256",name:"_userMinStakeFraction",type:"uint256"},{internalType:"uint256",name:"_maxVoteFraction",type:"uint256"},{internalType:"uint256",name:"_stakePeriod",type:"uint256"},{internalType:"uint256",name:"_submitPeriod",type:"uint256"},{internalType:"uint256",name:"_revealPeriod",type:"uint256"},{internalType:"uint256",name:"_escalationPeriod",type:"uint256"}],name:"initialise",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_domainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_altTarget",type:"address"},{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"createMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"uint256",name:"_amount",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"stakeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_voteSecret",type:"bytes32"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"submitVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"bytes32",name:"_salt",type:"bytes32"},{internalType:"uint256",name:"_vote",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"revealVote",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_newDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"bytes",name:"_key",type:"bytes"},{internalType:"bytes",name:"_value",type:"bytes"},{internalType:"uint256",name:"_branchMask",type:"uint256"},{internalType:"bytes32[]",name:"_siblings",type:"bytes32[]"}],name:"escalateMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"finalizeMotion",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"failingExecutionAllowed",outputs:[{internalType:"bool",name:"_allowed",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimReward",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"getTotalStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getVoterRewardFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getUserMinStakeFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMaxVoteFraction",outputs:[{internalType:"uint256",name:"_fraction",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getStakePeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getSubmitPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getRevealPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getEscalationPeriod",outputs:[{internalType:"uint256",name:"_period",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotion",outputs:[{components:[{internalType:"uint64[3]",name:"events",type:"uint64[3]"},{internalType:"bytes32",name:"rootHash",type:"bytes32"},{internalType:"uint256",name:"domainId",type:"uint256"},{internalType:"uint256",name:"skillId",type:"uint256"},{internalType:"uint256",name:"skillRep",type:"uint256"},{internalType:"uint256",name:"repSubmitted",type:"uint256"},{internalType:"uint256",name:"paidVoterComp",type:"uint256"},{internalType:"uint256[2]",name:"pastVoterComp",type:"uint256[2]"},{internalType:"uint256[2]",name:"stakes",type:"uint256[2]"},{internalType:"uint256[2]",name:"votes",type:"uint256[2]"},{internalType:"bool",name:"escalated",type:"bool"},{internalType:"bool",name:"finalized",type:"bool"},{internalType:"address",name:"altTarget",type:"address"},{internalType:"bytes",name:"action",type:"bytes"}],internalType:"struct VotingReputationDataTypes.Motion",name:"_motion",type:"tuple"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStake",outputs:[{internalType:"uint256",name:"_stake",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_structHash",type:"bytes32"}],name:"getExpenditureMotionCount",outputs:[{internalType:"uint256",name:"_count",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_actionHash",type:"bytes32"}],name:"getExpenditurePastVote",outputs:[{internalType:"uint256",name:"_vote",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"}],name:"getMotionState",outputs:[{internalType:"enum VotingReputationDataTypes.MotionState",name:"_motionState",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"}],name:"getVoterReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_voterRep",type:"uint256"},{internalType:"address",name:"_voterAddress",type:"address"}],name:"getVoterRewardRange",outputs:[{internalType:"uint256",name:"_rewardMin",type:"uint256"},{internalType:"uint256",name:"_rewardMax",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"getStakerReward",outputs:[{internalType:"uint256",name:"_reward",type:"uint256"},{internalType:"uint256",name:"_penalty",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes",name:"_action",type:"bytes"},{internalType:"uint256",name:"_value",type:"uint256"}],name:"createClaimDelayAction",outputs:[{internalType:"bytes",name:"_delayAction",type:"bytes"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"_motionId",type:"uint256"},{internalType:"uint256",name:"_permissionDomainId",type:"uint256"},{internalType:"uint256",name:"_childSkillIndex",type:"uint256"},{internalType:"address",name:"_staker",type:"address"},{internalType:"uint256",name:"_vote",type:"uint256"}],name:"claimMisalignedReward",outputs:[],stateMutability:"nonpayable",type:"function"}],Wi=class{static createInterface(){return new te.Interface(qp)}static connect(e,t){return new oe(e,qp,t)}};Wi.abi=qp;var{AddressZero:zp}=xt;var $u=F.from(10).pow(18),jn=class{static async connect(e){let t=await e.colonyNetwork.getInternalNetworkContract().getExtensionInstallation(ja(jn.extensionType),e.address);if(t===zp)throw new Error(`${jn.extensionType} extension is not installed for this Colony`);let n=await Or(t,e.colonyNetwork.signerOrProvider);if(!Ha(jn.extensionType,n,e.version))throw new Error(`Version ${n} of the ${jn.extensionType} contract is not compatible with the installed Colony contract version ${e.version}`);let i=jn.supportedVersions.find(s=>s.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the ${jn.extensionType} contract is not supported in the SDK as of now`);let r=i.connect(t,e.colonyNetwork.signerOrProvider);return new jn(e,r,n)}static getLatestSupportedVersion(){return jn.supportedVersions[jn.supportedVersions.length-1]?.version}constructor(e,t,n){this.address=t.address,this.colony=e,this.votingReputationContract=t,this.version=n}async createMotionSalt(e){let{address:t}=this.votingReputationContract,n=F.from(e).toNumber(),i=`Sign this message to generate 'salt' entropy. Extension Address: ${t} Motion ID: ${n}`,r=await this.colony.getInternalColonyContract().signer.signMessage(i);return te.keccak256(r)}async getSideVoted(e,t,n){let{key:i,value:r,branchMask:s,siblings:o}=n,l;try{await this.votingReputationContract.estimateGas.revealVote(e,t,0,i,r,s,o),l=0}catch(p){if(p.message.includes("voting-rep-secret-no-match"))try{await this.votingReputationContract.estimateGas.revealVote(e,t,1,i,r,s,o),l=1}catch{}}return l}getInternalVotingReputationContract(){return this.votingReputationContract}initialize(e,t,n,i,r,s,o,l){return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"initialise",[e,t,n,i,r,s,o,l],async p=>({...ne("ExtensionInitialised",p)}))}async getMotion(e){if((await this.votingReputationContract.getMotionCount()).lt(e))throw new Error(`Motion with id ${e} does not exist`);return this.votingReputationContract.getMotion(e)}async getMotionResult(e){if(await this.getMotionState(e){let{actionCid:t,key:n,value:i,branchMask:r,siblings:s}=await Bs(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),this.colony.reputation,this.votingReputationContract,e,zp,ql);return[e,t,zp,ql,n,i,r,s]},async t=>({...ne("MotionCreated",t)}))}annotateDecision(e,t){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colony.colonyNetwork.ipfs.uploadMetadata(Pe.Decision,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Pe.Decision})}approveStake(e,t=ke.RootDomain){return this.colony.colonyNetwork.createMetaTxCreator(this.colony.getInternalColonyContract(),"approveStake",[this.votingReputationContract.address,t,e],async n=>{let i=await this.colony.colonyNetwork.getTokenLocking();return{...Ju("UserTokenApproved",n,i.getInternalTokenLockingContract().interface)}})}stakeMotion(e,t,n){let i=async()=>{let r=await this.colony.colonyNetwork.getSigner().getAddress(),s=await this.votingReputationContract.getMotionState(e);if(s!==Ot.Staking)throw new Error(`Motion cannot be staked. It's currently in "${Ot[s]}" state`);let o=await this.getMotion(e),l=await this.colony.colonyNetwork.getTokenLocking();if((await l.getUserDeposit(this.colony.token.address,r)).lt(n))throw new Error("Not enough tokens deposited for staking.");if((await l.getUserApproval(this.colony.token.address,r,this.colony.address)).lt(n))throw new Error("Not enough tokens approved for staking in the Colony.");if((await this.colony.getInternalColonyContract().getApproval(r,this.address,o.domainId)).lt(n))throw new Error("Not enough tokens approved for staking in the VotingReputation contract.");if(o.events[0].mul(1e3).lte(Date.now()))throw new Error("The staking period for this Motion has passed already.");let C=await this.getMinStake(o,t);if(F.from(n).lt(C))throw new Error(`The staked amount is too small. Please stake at least ${Nr(C)}`);let{domainId:_,rootHash:v}=await this.getMotion(e),[S,L]=await ra(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),_,wt.Arbitration,this.address),{skillId:O}=await this.colony.getTeam(_),{key:U,value:H,branchMask:M,siblings:J}=await this.colony.reputation.getReputationWithProofs(O,r,v);return[e,S,L,F.from(t),n,U,H,M,J]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"stakeMotion",i,async r=>({...ne("MotionStaked",r),...ne("MotionEventSet",r)}))}submitVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Ot.Submit)throw new Error(`Motion cannot be voted on at this time. It's currently in "${Ot[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),{key:p,value:c,branchMask:x,siblings:C}=await this.colony.reputation.getReputationWithProofs(o,l,s),_=await this.createMotionSalt(e),v=te.solidityKeccak256(["bytes","uint256"],[_,t]);return[e,v,p,c,x,C]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"submitVote",n,async i=>({...ne("MotionVoteSubmitted",i)}))}revealVote(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Ot.Reveal)throw new Error(`Motion cannot be revealed at this time. It's currently in "${Ot[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(r),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await this.colony.reputation.getReputationWithProofs(o,l,s),c=await this.createMotionSalt(e),x=t||await this.getSideVoted(e,c,p);if(!x)throw new Error(`Could not find a vote cast by ${l} for motion ${e}`);let{key:C,value:_,branchMask:v,siblings:S}=p;return[e,c,F.from(x),C,_,v,S]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"revealVote",n,async i=>({...ne("MotionVoteRevealed",i)}))}escalateMotion(e,t){let n=async()=>{let i=await this.votingReputationContract.getMotionState(e);if(i!==Ot.Closed)throw new Error(`Motion cannot be escalated at this time. It's currently in "${Ot[i]}" state`);let{domainId:r,rootHash:s}=await this.getMotion(e),{skillId:o}=await this.colony.getTeam(t),l=await this.colony.colonyNetwork.getSigner().getAddress(),p=await Ei(this.colony.colonyNetwork.getInternalNetworkContract(),this.colony.getInternalColonyContract(),t,r),{key:c,value:x,branchMask:C,siblings:_}=await this.colony.reputation.getReputationWithProofs(o,l,s);return[e,t,p,c,x,C,_]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"escalateMotion",n,async i=>({...ne("MotionEscalated",i)}))}finalizeMotion(e){let t=async()=>{let n=await this.votingReputationContract.getMotionState(e);if(n!==Ot.Finalizable)throw new Error(`Motion cannot be finalized. It's currently in "${Ot[n]}" state`);return[e]};return this.colony.colonyNetwork.createMetaTxCreator(this.votingReputationContract,"finalizeMotion",t,async n=>({...ne("MotionFinalized",n)}))}upgrade(e){let t=e||this.version+1;return this.colony.createColonyTxCreator(this.colony.getInternalColonyContract(),"upgradeExtension",[ja(we.VotingReputation),t],async n=>({...ne("ExtensionUpgraded",n)}))}async getInitializationOptions(){let e=[this.votingReputationContract.getTotalStakeFraction(),this.votingReputationContract.getVoterRewardFraction(),this.votingReputationContract.getUserMinStakeFraction(),this.votingReputationContract.getMaxVoteFraction(),this.votingReputationContract.getStakePeriod(),this.votingReputationContract.getSubmitPeriod(),this.votingReputationContract.getRevealPeriod(),this.votingReputationContract.getEscalationPeriod()],[t,n,i,r,s,o,l,p]=await Promise.all(e);return{requiredStake:t,voterReward:n,minimumUserStake:i,endVoteThreshold:r,stakePhaseDuration:s,votingPhaseDuration:o,revealPhaseDuration:l,escalationPhaseDuration:p}}},Wa=jn;Wa.supportedVersions=[{version:7,factory:zi},{version:8,factory:Gi},{version:9,factory:Wi}],Wa.extensionType=we.VotingReputation;var mg={["motion"]:Wa,["oneTx"]:Ga},Hr=class{static async connect(e,t){let n=await Or(t,e.signerOrProvider),i=Hr.supportedVersions.find(p=>p.version===n)?.factory;if(!i)throw new Error(`Version ${n} of the Colony contract is not supported in the SDK as of now`);let r=i.connect(t,e.signerOrProvider),s=await r.getToken(),o=await Vh(e,s),l=new Hr(e,r,o,n);return await l.updateExtensions(),l}static getLatestSupportedVersion(){return Hr.supportedVersions[Hr.supportedVersions.length-1].version}constructor(e,t,n,i){this.colony=t,this.colonyNetwork=e,this.address=t.address,this.ext={},this.reputation=new sa(e.getInternalNetworkContract(),t,{customEndpointUrl:e.config.reputationOracleEndpoint}),this.token=n,this.version=i}createColonyTxCreator(e,t,n,i,r){return new jr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,eventData:i,txConfig:r})}createPermissionedColonyTxCreator(e,t,n,i,r,s){return new jr({colony:this,colonyNetwork:this.colonyNetwork,contract:e,method:t,args:n,permissionConfig:i,eventData:r,txConfig:s})}getInternalColonyContract(){return this.colony}async updateExtensions(){if(!this.ext.motions)try{this.ext.motions=await Wa.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}if(!this.ext.oneTx)try{this.ext.oneTx=await Ga.connect(this)}catch(e){typeof process<"u"&&process?.env?.DEBUG&&console.error(e)}}async getBalance(e,t){if(t){let{fundingPotId:i}=await this.colony.getDomain(t),r=i,s=e||this.token.address;return this.colony.getFundingPotBalance(r,s)}return(e?new Vn(this.colonyNetwork,e):this.token).balanceOf(this.address)}edit(e){return this.createColonyTxCreator(this.colony,"editColony",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Colony,e),[t]},async t=>({...ne("ColonyMetadata",t)}),{metadataType:Pe.Colony})}createTeam(e){return e?this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256,string)",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Domain,e),[ke.RootDomain,t]},{roles:wt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t),...ne("DomainMetadata",t)}),{metadataType:Pe.Domain}):this.createPermissionedColonyTxCreator(this.colony,"addDomain(uint256,uint256,uint256)",[ke.RootDomain],{roles:wt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainAdded",t),...ne("FundingPotAdded",t)}))}editTeam(e){return this.createPermissionedColonyTxCreator(this.colony,"editDomain",async()=>{let t;return typeof e=="string"?t=e:t=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Domain,e),[ke.RootDomain,t]},{roles:wt.Architecture,domain:ke.RootDomain},async t=>({...ne("DomainMetadata",t)}),{metadataType:Pe.Domain})}deprecateTeam(e,t){return this.createPermissionedColonyTxCreator(this.colony,"deprecateDomain",[e,t],{roles:wt.Architecture,domain:e},async n=>({...ne("DomainDeprecated",n)}))}async getTeam(e){if((await this.colony.getDomainCount()).lt(e))throw new Error(`Team with id ${e} does not exist`);return this.colony.getDomain(e)}claimFunds(e){let t=e||this.token.address;return this.createColonyTxCreator(this.colony,"claimColonyFunds",[t],async n=>({...ne("ColonyFundsClaimed",n)}))}moveFundsToTeam(e,t,n,i){let r=ke.RootDomain,s=n||ke.RootDomain,o=i||this.token.address;return this.createColonyTxCreator(this.colony,"moveFundsBetweenPots(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address)",async()=>{if((await this.colony.getDomain(t)).fundingPotId.isZero())throw new Error(`Team with id ${F.from(t).toString()} does not exist`);let[p,c]=await ra(this.colonyNetwork.getInternalNetworkContract(),this.colony,r,wt.Funding),x=this.colonyNetwork.getInternalNetworkContract(),C=await Ei(x,this.colony,r,s),_=await Ei(x,this.colony,r,t),{fundingPotId:v}=await this.colony.getDomain(s),{fundingPotId:S}=await this.colony.getDomain(t);return[p,c,r,C,_,v,S,e,o]},async l=>({...ne("ColonyFundsMovedBetweenFundingPots",l)}))}async getReputation(e,t=ke.RootDomain,n=3){let{skillId:i}=await this.colony.getDomain(t);return this.reputation.getReputationFraction(i,e,void 0,n)}async getReputationPoints(e,t=ke.RootDomain){let{skillId:n}=await this.colony.getDomain(t),{reputationAmount:i}=await this.reputation.getReputation(n,e);return i}async getReputationAcrossTeams(e){return this.reputation.getReputationAcrossDomains(e)}makeArbitraryTransaction(e,t){return this.createColonyTxCreator(this.colony,"makeArbitraryTransactions",[[e],[t],!1],async n=>({...ne("ArbitraryTransaction",n)}))}annotateTransaction(e,t){return this.createColonyTxCreator(this.colony,"annotateTransaction",async()=>{let n;return typeof t=="string"?n=t:n=await this.colonyNetwork.ipfs.uploadMetadata(Pe.Annotation,t),[e,n]},async n=>({...ne("Annotation",n)}),{metadataType:Pe.Annotation})}installExtension(e){let t=mg[e],n=t.getLatestSupportedVersion(),{extensionType:i}=t;if(!Ha(i,n,this.version))throw new Error(`v${n} of ${i} extension is not compatible with colony v${this.version}`);let r=this.colonyNetwork.getInternalNetworkContract();return this.createColonyTxCreator(this.colony,"installExtension",[ja(i),t.getLatestSupportedVersion()],async s=>({...Ju("ExtensionInstalled",s,r.interface)}))}async getRoles(e,t=ke.RootDomain){let n=await this.colony.getUserRoles(e,t);return cu(n)}setRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let i=await this.getRoles(e,n),r=Array.from(new Set([...i,...[].concat(t)])),s=Kl(r);return[e,n,s]},{roles:wt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}unsetRoles(e,t,n=ke.RootDomain){return this.createPermissionedColonyTxCreator(this.colony,"setUserRoles",async()=>{let r=(await this.getRoles(e,n)).filter(o=>![].concat(t).includes(o)),s=Kl(r);return[e,n,s]},{roles:wt.Architecture,domain:n},async i=>({...ne("ColonyRoleSet",i),...ne("RecoveryRoleSet",i)}))}mint(e){return this.createColonyTxCreator(this.colony,"mintTokens",[e],async t=>({...ne("TokensMinted",t)}))}deployTokenAuthority(e){let t=this.colonyNetwork.getInternalNetworkContract();return this.colonyNetwork.createMetaTxCreator(t,"deployTokenAuthority",async()=>{let n=[],i=await t.getTokenLocking();return e?n=[...e,i]:n=[i],[this.token.address,this.address,n]},async n=>({...ne("TokenAuthorityDeployed",n)}))}enterRecoveryMode(){return this.createColonyTxCreator(this.colony,"enterRecoveryMode",[],async e=>({...ne("RecoveryModeEntered",e)}))}exitRecoveryMode(){return this.createColonyTxCreator(this.colony,"exitRecoveryMode",[],async e=>({...ne("RecoveryModeExited",e)}))}upgrade(e){let t=e||this.version+1;return this.createColonyTxCreator(this.colony,"upgrade",[t],async n=>({...ne("ColonyUpgraded",n)}))}awardReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation award must be bigger than 0");return this.createColonyTxCreator(this.colony,"emitDomainReputationReward",[n,e,t],async i=>({...ne("ArbitraryReputationUpdate",i)}))}smiteReputation(e,t,n=ke.RootDomain){if(F.from(t).lte(0))throw new Error("Reputation smite must be bigger than 0");return this.createPermissionedColonyTxCreator(this.colony,"emitDomainReputationPenalty",[n,e,F.from(0).sub(t)],{domain:n,roles:wt.Arbitration},async i=>({...ne("ArbitraryReputationUpdate",i)}))}},qr=Hr;qr.supportedVersions=[{version:11,factory:Li},{version:12,factory:Ui},{version:13,factory:Vi}];var{splitSignature:hg}=te,Qu=class extends ka{async getMetaTx(){let e=await this.getArgs();return this.sendMetaTransaction(this.contract.address,e)}async getMetaMined(e){let t=await this.waitForMetaTx(e);return this.getEventData(t)}async sendMetaTransaction(e,[t,n]){if(!this.colonyNetwork.config.metaTxBroadcasterEndpoint)throw new Error(`No metatransaction broadcaster endpoint found for network ${this.colonyNetwork.network}`);let i=this.colonyNetwork.getSigner(),{provider:r}=i;if(!r)throw new Error("No provider found");let s;this.colonyNetwork.network===Fn.Custom?s=1:s=(await r.getNetwork()).chainId;let o=await i.getAddress(),l=await this.contract.functions.nonces(o),p=await this.contract.name(),c=Math.floor(Date.now()/1e3)+3600,x=await i._signTypedData({name:p,version:"1",chainId:s,verifyingContract:this.contract.address},{Permit:[{name:"owner",type:"address"},{name:"spender",type:"address"},{name:"value",type:"uint256"},{name:"nonce",type:"uint256"},{name:"deadline",type:"uint256"}]},{owner:o,spender:t,value:n,nonce:l.toString(),deadline:c}),{r:C,s:_,v}=hg(x),S={target:e,owner:o,spender:t,value:n.toString(),deadline:c,r:C,s:_,v};return this.broadcastMetaTx(S)}tx(){if(this.method==="permit")throw new Error('Only MetaTransactions are supported for this method. Please use "approve" instead.');return super.tx.apply(this)}metaTx(){if(this.method!=="permit")throw new Error('Only the "permit" function is allowed to be sent as MetaTransaction per EIP-2612');return{send:async()=>{let e=await this.getMetaTx();return[e,this.getMetaMined.bind(this,e)]},mined:async()=>{let e=await this.getMetaTx();return this.getMetaMined(e)}}}};var $s=class{constructor(e,t){this.address=t,this.colonyNetwork=e,this.tokenLockingContract=Sp(this.address,e.signerOrProvider)}getInternalTokenLockingContract(){return this.tokenLockingContract}deposit(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"deposit(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenDeposited",n)}))}withdraw(e,t){return this.colonyNetwork.createMetaTxCreator(this.tokenLockingContract,"withdraw(address,uint256,bool)",[e,t,!1],async n=>({...ne("UserTokenWithdrawn",n)}))}async getUserDeposit(e,t){return(await this.tokenLockingContract.getUserLock(e,t)).balance}async getUserApproval(e,t,n){return this.tokenLockingContract.getApproval(t,e,n)}};var{namehash:jh}=te,{AddressZero:Gp}=xt,Qs=class{constructor(e,t){this.network=t?.network||Fn.Gnosis,this.ipfs=new Vr(t?.ipfsAdapter),this.config={metaTxBroadcasterEndpoint:t?.metaTxBroadcasterEndpoint||yu[this.network],reputationOracleEndpoint:t?.reputationOracleEndpoint||Pr[this.network]},this.networkContract=Bi.connect(t?.customNetworkAddress||pu[this.network],e),this.signerOrProvider=e}getSigner(){if(!(this.signerOrProvider instanceof Pt))throw new Error("Need a signer to create a transaction");return this.signerOrProvider}async getTokenLocking(){if(!this.locking){let e=await this.networkContract.getTokenLocking();this.locking=new $s(this,e)}return this.locking}getInternalNetworkContract(){return this.networkContract}createTxCreator(e,t,n,i,r){return new ka({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createMetaTxCreator(e,t,n,i,r){return new Fi({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createEip2612TxCreator(e,t,n,i,r){return new Qu({colonyNetwork:this,contract:e,method:t,args:n,eventData:i,txConfig:r})}createColony(e,t,n){let i=async()=>{if(await this.getColonyAddress(t))throw new Error(`Colony with label ${t} already exists`);if(typeof e!="string"){if(!e.name)throw new Error("Token name is required");if(!e.symbol)throw new Error("Token symbol is required");return[Gp,e.name,e.symbol,e.decimals||18,0,t,""]}return[e,"","",0,0,t,""]};return n?this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",async()=>{let r=await i();return typeof n=="string"?r[6]=n:r[6]=await this.ipfs.uploadMetadata(Pe.Colony,n),r},async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}),{metadataType:Pe.Colony}):this.createMetaTxCreator(this.networkContract,"createColonyForFrontend",i,async r=>({...ne("TokenDeployed",r),...ne("ColonyAdded",r),...ne("TokenAuthorityDeployed",r)}))}async getColony(e){return qr.connect(this,e)}async getMetaColony(){let e=await this.networkContract.getMetaColony();return this.getColony(e)}async getColonyLabel(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Ds[this.network],""):null}async getColonyAddress(e){let t=jh(`${e}${Ds[this.network]}`),n=await this.networkContract.addr(t);return n!==Gp?n:null}async getUsername(e){let t=await this.networkContract.lookupRegisteredENSDomain(e);return t?t.replace(Os[this.network],""):null}async getUserAddress(e){let t=jh(`${e}${Os[this.network]}`),n=await this.networkContract.addr(t);return n!==Gp?n:null}registerUsername(e){let t=async()=>{if(await this.getColonyAddress(e))throw new Error(`Username ${e} is already taken`);return[e,""]};return this.createMetaTxCreator(this.networkContract,"registerUserLabel",t,async n=>({...ne("UserLabelRegistered",n)}))}deployToken(e,t,n=18){return this.createMetaTxCreator(this.networkContract,"deployTokenViaNetwork",[e,t,n],async i=>({...ne("TokenDeployed",i)}))}};var{isAddress:bg}=te,Hh=new ia.Web3Provider(window.ethereum),Gh,qh,Rt,ln,Kp,gg=async()=>(await Hh.send("eth_requestAccounts",[]),Hh.getSigner()),Tg=async a=>{let e=await gg();Gh=await e.getAddress(),qh=new Qs(e),Rt=await qh.getColony(a)},vg=async a=>{if(!Rt.ext.motions||!Rt.ext.oneTx)throw new Error("Motions & Disputes extension not installed");let[{motionId:e}]=await Rt.ext.oneTx.pay("0x27ff0c145e191c22c75cd123c679c3e1f58a4469",Dr(a)).motion().mined();if(!e)throw new Error("Could not get motionId from tx");return e},wg=async a=>{if(!Rt.ext.motions)throw new Error("Motions & Disputes extension not installed");let e=await Rt.ext.motions.getMotion(a);ln=F.from(a);let t=await Rt.ext.motions.getRemainingStakes(a),n=await Rt.ext.motions.getMotionState(a);return{...e,motionState:Ot[n],remainingStakes:t}},_g=async a=>{await Rt.ext.motions?.approveStake(Dr(a)).tx().mined()},kg=async a=>{await Rt.ext.motions?.stakeMotion(ln,1,a).tx().mined()},Ag=async a=>{await Rt.ext.motions?.stakeMotion(ln,0,a).tx().mined()},Eg=async()=>{await Rt.ext.motions?.submitVote(ln,1).tx().mined(),Kp=1},Mg=async()=>{await Rt.ext.motions?.submitVote(ln,0).tx().mined(),Kp=0},Ig=async()=>{await Rt.ext.motions?.revealVote(ln,Kp).tx().mined()},Cg=async()=>{await Rt.ext.motions?.finalizeMotion(ln).tx().mined()},zh=document.querySelector("#current-wallet-address"),Yu=document.querySelector("#address"),Wh=document.querySelector("#stake_clny_amount"),Wp=document.querySelector("#payment_amount"),Jp=document.querySelector("#stake_amount"),Kh=document.querySelector("#button_create_motion"),Jh=document.querySelector("#motion_id"),$h=document.querySelector("#button_connect"),Qh=document.querySelector("#button_stake_clny"),Yh=document.querySelector("#button_get_motion"),Xh=document.querySelector("#button_stake_yay"),Zh=document.querySelector("#button_stake_nay"),e6=document.querySelector("#button_vote_yay"),t6=document.querySelector("#button_vote_nay"),n6=document.querySelector("#button_reveal"),a6=document.querySelector("#button_finalize"),$p=document.querySelector("#error"),i6=document.querySelector("#result");if(!Yu||!Wh||!Wp||!Jh||!Jp||!$p||!i6||!$h||!Qh||!Kh||!Yh||!Xh||!Zh||!e6||!t6||!n6||!a6)throw new Error("Could not find all required HTML elements");var Bt=a=>{$p.innerText=`Found an error: ${a.message}`,console.error(a)},Aa=()=>{$p.innerText=""},Ie=a=>{i6.innerText=a};$h.addEventListener("click",async()=>{Aa();let a=Yu.value;if(!bg(a))return Bt(new Error("This is not a valid address"));Ie("Processing...");try{await Tg(Yu.value),zh&&(zh.innerText=Gh),Ie(` Connected to Colony with address: ${Rt.address}. Colony version: ${Rt.version}. Motions & Disputes extension is ${Rt.ext.motions?"installed":"not installed"}