12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959(* generated by: awso-codegen generate-all --botocore-data vendor/botocore/botocore/data -o aws --runtime-dir lib/runtime/awso --cli-dir awso-cli *)openAwsoopen!Import[@@@warning"-32"]letservice=Service.managedblockchain_queryletapiVersion="2023-05-04"letendpointPrefix="managedblockchain-query"letserviceFullName="Amazon Managed Blockchain Query"letsignatureVersion="v4"letprotocol="rest_json"letglobalEndpoint=endpointPrefix^".amazonaws.com"letsimple_to_jsonto_valuex=Botodata.Json.value_to_json_scalar(to_valuex)letcomposed_to_jsonto_valuex=Botodata.Json.value_to_json(to_valuex)letto_queryto_valuex=Client.Query.of_value(to_valuex)letstructure_to_value_auxst~f=letfilter=function|(k,Somev)->Some(k,v)|_->Noneinletpairkv=(k,v)inletdefer_value(k,dv)=pairkdvin((List.filter_mapst~f:filter)|>(List.map~f:defer_value))|>(funx->`Structure(fx))letstructure_to_value=structure_to_value_aux~f:Fn.idletstructure_to_wrapped_value~wrapper~response=structure_to_value_aux~f:(funx->[(wrapper,(`Structurex));(response,(`Structure[]))])moduleString_=structtypenonrect=stringletcontext_="String"letmakei=iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"String"jletto_json=simple_to_jsonto_valueendmoduleTimestamp=structtypenonrect=stringletmakei=iletof_stringx=xletto_valuex=`Timestampxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=string_of_xml~kind:"a timestamp"letof_json=timestamp_of_jsonletto_json=simple_to_jsonto_valueendmoduleChainAddress=structtypenonrect=stringletcontext_="ChainAddress"letmakei=letopenResultinok_or_failwith(check_patterni~pattern:"[-A-Za-z0-9]{13,74}");iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"ChainAddress"jletto_json=simple_to_jsonto_valueendmoduleQueryNetwork=structtypenonrect=|ETHEREUM_MAINNET|ETHEREUM_SEPOLIA_TESTNET|BITCOIN_MAINNET|BITCOIN_TESTNET|Non_static_idofstringletmakei=iletto_string=function|ETHEREUM_MAINNET->"ETHEREUM_MAINNET"|ETHEREUM_SEPOLIA_TESTNET->"ETHEREUM_SEPOLIA_TESTNET"|BITCOIN_MAINNET->"BITCOIN_MAINNET"|BITCOIN_TESTNET->"BITCOIN_TESTNET"|Non_static_ids->sletof_string=function|"ETHEREUM_MAINNET"->ETHEREUM_MAINNET|"ETHEREUM_SEPOLIA_TESTNET"->ETHEREUM_SEPOLIA_TESTNET|"BITCOIN_MAINNET"->BITCOIN_MAINNET|"BITCOIN_TESTNET"->BITCOIN_TESTNET|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration QueryNetwork"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"QueryNetwork"j)letto_json=simple_to_jsonto_valueendmoduleQueryTokenId=structtypenonrect=stringletcontext_="QueryTokenId"letmakei=letopenResultinok_or_failwith(check_patterni~pattern:"[a-zA-Z0-9]{1,66}");iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"QueryTokenId"jletto_json=simple_to_jsonto_valueendmoduleConfirmationStatus=structtypenonrect=|FINAL|NONFINAL|Non_static_idofstringletmakei=iletto_string=function|FINAL->"FINAL"|NONFINAL->"NONFINAL"|Non_static_ids->sletof_string=function|"FINAL"->FINAL|"NONFINAL"->NONFINAL|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ConfirmationStatus"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ConfirmationStatus"j)letto_json=simple_to_jsonto_valueendmoduleQueryTransactionHash=structtypenonrect=stringletcontext_="QueryTransactionHash"letmakei=letopenResultinok_or_failwith(check_patterni~pattern:"(0x[A-Fa-f0-9]{64}|[A-Fa-f0-9]{64})");iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"QueryTransactionHash"jletto_json=simple_to_jsonto_valueendmoduleQueryTransactionId=structtypenonrect=stringletcontext_="QueryTransactionId"letmakei=letopenResultinok_or_failwith(check_patterni~pattern:"(0x[A-Fa-f0-9]{64}|[A-Fa-f0-9]{64})");iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"QueryTransactionId"jletto_json=simple_to_jsonto_valueendmoduleValidationExceptionField=structtypenonrect={name:String_.toption[@ocaml.doc"The name of the field that triggered the ValidationException."];message:String_.toption[@ocaml.doc"The ValidationException message."]}letmake?name=fun?message->fun()->{name;message}letto_valuex=structure_to_value[("name",(Option.mapx.name~f:String_.to_value));("message",(Option.mapx.message~f:String_.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmessage=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"message")inletname=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"name")inmake?message?name()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmessage=field_mapjson__"message"String_.of_jsoninletname=field_mapjson__"name"String_.of_jsoninmake?message?name()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The resource passed is invalid."]moduleBlockchainInstant=structtypenonrect={time:Timestamp.toption[@ocaml.doc"The container of the Timestamp of the blockchain instant. This timestamp will only be recorded up to the second."]}letmake?time=fun()->{time}letto_valuex=structure_to_value[("time",(Option.mapx.time~f:Timestamp.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=lettime=(Option.map~f:Timestamp.of_xml)(Xml.childxml_arg0"time")inmake?time()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=lettime=field_mapjson__"time"Timestamp.of_jsoninmake?time()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for time."]moduleBoolean=structtypenonrect=boolletmakei=iletof_string=Bool.of_stringletto_valuex=`Booleanxletto_queryv=to_queryto_valuevletto_headerx=Bool.to_stringxletof_xmlxml_arg0=Bool.of_string(string_of_xml~kind:"a boolean"xml_arg0)letof_json=bool_of_jsonletto_json=simple_to_jsonto_valueendmoduleInteger=structtypenonrect=intletmakei=iletof_string=Int.of_stringletto_valuex=`Integerxletto_queryv=to_queryto_valuevletto_headerx=Int.to_stringxletof_xmlxml_arg0=Int.of_string(string_of_xml~kind:"an integer for Integer"xml_arg0)letof_jsonj=Int.of_float(float_of_json~kind:"an integer"j)letto_json=simple_to_jsonto_valueendmoduleQueryTransactionEventType=structtypenonrect=|ERC20_TRANSFER|ERC20_MINT|ERC20_BURN|ERC20_DEPOSIT|ERC20_WITHDRAWAL|ERC721_TRANSFER|ERC1155_TRANSFER|BITCOIN_VIN|BITCOIN_VOUT|INTERNAL_ETH_TRANSFER|ETH_TRANSFER|Non_static_idofstringletmakei=iletto_string=function|ERC20_TRANSFER->"ERC20_TRANSFER"|ERC20_MINT->"ERC20_MINT"|ERC20_BURN->"ERC20_BURN"|ERC20_DEPOSIT->"ERC20_DEPOSIT"|ERC20_WITHDRAWAL->"ERC20_WITHDRAWAL"|ERC721_TRANSFER->"ERC721_TRANSFER"|ERC1155_TRANSFER->"ERC1155_TRANSFER"|BITCOIN_VIN->"BITCOIN_VIN"|BITCOIN_VOUT->"BITCOIN_VOUT"|INTERNAL_ETH_TRANSFER->"INTERNAL_ETH_TRANSFER"|ETH_TRANSFER->"ETH_TRANSFER"|Non_static_ids->sletof_string=function|"ERC20_TRANSFER"->ERC20_TRANSFER|"ERC20_MINT"->ERC20_MINT|"ERC20_BURN"->ERC20_BURN|"ERC20_DEPOSIT"->ERC20_DEPOSIT|"ERC20_WITHDRAWAL"->ERC20_WITHDRAWAL|"ERC721_TRANSFER"->ERC721_TRANSFER|"ERC1155_TRANSFER"->ERC1155_TRANSFER|"BITCOIN_VIN"->BITCOIN_VIN|"BITCOIN_VOUT"->BITCOIN_VOUT|"INTERNAL_ETH_TRANSFER"->INTERNAL_ETH_TRANSFER|"ETH_TRANSFER"->ETH_TRANSFER|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration QueryTransactionEventType"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"QueryTransactionEventType"j)letto_json=simple_to_jsonto_valueendmoduleOwnerIdentifier=structtypenonrect={address:ChainAddress.t[@ocaml.doc"The contract or wallet address for the owner."]}letcontext_="OwnerIdentifier"letmake~address=fun()->{address}letto_valuex=structure_to_value[("address",(Some(ChainAddress.to_valuex.address)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letaddress=ChainAddress.of_xml(Xml.child_exn~context:context_xml_arg0"address")inmake~address()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letaddress=field_map_exnjson__"address"ChainAddress.of_jsoninmake~address()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the owner identifier."]moduleTokenIdentifier=structtypenonrect={network:QueryNetwork.t[@ocaml.doc"The blockchain network of the token."];contractAddress:ChainAddress.toption[@ocaml.doc"This is the token's contract address."];tokenId:QueryTokenId.toption[@ocaml.doc"The unique identifier of the token. For native tokens, use the 3 character abbreviation that best matches your token. For example, btc for Bitcoin, eth for Ether, etc. For all other token types you must specify the tokenId in the 64 character hexadecimal tokenid format."]}letcontext_="TokenIdentifier"letmake?contractAddress=fun?tokenId->fun~network->fun()->{contractAddress;tokenId;network}letto_valuex=structure_to_value[("network",(Some(QueryNetwork.to_valuex.network)));("contractAddress",(Option.mapx.contractAddress~f:ChainAddress.to_value));("tokenId",(Option.mapx.tokenId~f:QueryTokenId.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=lettokenId=(Option.map~f:QueryTokenId.of_xml)(Xml.childxml_arg0"tokenId")inletcontractAddress=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"contractAddress")inletnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inmake?tokenId?contractAddress~network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=lettokenId=field_mapjson__"tokenId"QueryTokenId.of_jsoninletcontractAddress=field_mapjson__"contractAddress"ChainAddress.of_jsoninletnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninmake?tokenId?contractAddress~network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the identifier for the token including the unique token ID and its blockchain network. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported."]moduleContractIdentifier=structtypenonrect={network:QueryNetwork.t[@ocaml.doc"The blockchain network of the contract."];contractAddress:ChainAddress.t[@ocaml.doc"Container for the blockchain address about a contract."]}letcontext_="ContractIdentifier"letmake~network=fun~contractAddress->fun()->{network;contractAddress}letto_valuex=structure_to_value[("network",(Some(QueryNetwork.to_valuex.network)));("contractAddress",(Some(ChainAddress.to_valuex.contractAddress)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letcontractAddress=ChainAddress.of_xml(Xml.child_exn~context:context_xml_arg0"contractAddress")inletnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inmake~contractAddress~network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letcontractAddress=field_map_exnjson__"contractAddress"ChainAddress.of_jsoninletnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninmake~contractAddress~network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Container for the blockchain address and network information about a contract."]moduleQueryTokenStandard=structtypenonrect=|ERC20|ERC721|ERC1155|Non_static_idofstringletmakei=iletto_string=function|ERC20->"ERC20"|ERC721->"ERC721"|ERC1155->"ERC1155"|Non_static_ids->sletof_string=function|"ERC20"->ERC20|"ERC721"->ERC721|"ERC1155"->ERC1155|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration QueryTokenStandard"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"QueryTokenStandard"j)letto_json=simple_to_jsonto_valueendmoduleErrorType=structtypenonrect=|VALIDATION_EXCEPTION|RESOURCE_NOT_FOUND_EXCEPTION|Non_static_idofstringletmakei=iletto_string=function|VALIDATION_EXCEPTION->"VALIDATION_EXCEPTION"|RESOURCE_NOT_FOUND_EXCEPTION->"RESOURCE_NOT_FOUND_EXCEPTION"|Non_static_ids->sletof_string=function|"VALIDATION_EXCEPTION"->VALIDATION_EXCEPTION|"RESOURCE_NOT_FOUND_EXCEPTION"->RESOURCE_NOT_FOUND_EXCEPTION|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ErrorType"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ErrorType"j)letto_json=simple_to_jsonto_valueendmoduleExceptionMessage=structtypenonrect=stringletcontext_="ExceptionMessage"letmakei=letopenResultinok_or_failwith(check_string_mini~min:1);iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"ExceptionMessage"jletto_json=simple_to_jsonto_valueendmoduleQuotaCode=structtypenonrect=stringletcontext_="QuotaCode"letmakei=iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"QuotaCode"jletto_json=simple_to_jsonto_valueendmoduleResourceId=structtypenonrect=stringletcontext_="ResourceId"letmakei=iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"ResourceId"jletto_json=simple_to_jsonto_valueendmoduleResourceType=structtypenonrect=|Collection|Non_static_idofstringletmakei=iletto_string=function|Collection->"collection"|Non_static_ids->sletof_string=function|"collection"->Collection|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ResourceType"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ResourceType"j)letto_json=simple_to_jsonto_valueendmoduleServiceCode=structtypenonrect=stringletcontext_="ServiceCode"letmakei=iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"ServiceCode"jletto_json=simple_to_jsonto_valueendmoduleTransactionOutputItem=structtypenonrect={transactionHash:QueryTransactionHash.toption[@ocaml.doc"The hash of a transaction. It is generated when a transaction is created."];transactionId:QueryTransactionId.toption[@ocaml.doc"The identifier of a Bitcoin transaction. It is generated when a transaction is created."];network:QueryNetwork.toption[@ocaml.doc"The blockchain network where the transaction occurred."];transactionTimestamp:Timestamp.toption[@ocaml.doc"The time when the transaction occurred."];confirmationStatus:ConfirmationStatus.toption[@ocaml.doc"Specifies whether to list transactions that have not reached Finality."]}letmake?transactionHash=fun?transactionId->fun?network->fun?transactionTimestamp->fun?confirmationStatus->fun()->{transactionHash;transactionId;network;transactionTimestamp;confirmationStatus}letto_valuex=structure_to_value[("transactionHash",(Option.mapx.transactionHash~f:QueryTransactionHash.to_value));("transactionId",(Option.mapx.transactionId~f:QueryTransactionId.to_value));("network",(Option.mapx.network~f:QueryNetwork.to_value));("transactionTimestamp",(Option.mapx.transactionTimestamp~f:Timestamp.to_value));("confirmationStatus",(Option.mapx.confirmationStatus~f:ConfirmationStatus.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letconfirmationStatus=(Option.map~f:ConfirmationStatus.of_xml)(Xml.childxml_arg0"confirmationStatus")inlettransactionTimestamp=(Option.map~f:Timestamp.of_xml)(Xml.childxml_arg0"transactionTimestamp")inletnetwork=(Option.map~f:QueryNetwork.of_xml)(Xml.childxml_arg0"network")inlettransactionId=(Option.map~f:QueryTransactionId.of_xml)(Xml.childxml_arg0"transactionId")inlettransactionHash=(Option.map~f:QueryTransactionHash.of_xml)(Xml.childxml_arg0"transactionHash")inmake?confirmationStatus?transactionTimestamp?network?transactionId?transactionHash()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letconfirmationStatus=field_mapjson__"confirmationStatus"ConfirmationStatus.of_jsoninlettransactionTimestamp=field_mapjson__"transactionTimestamp"Timestamp.of_jsoninletnetwork=field_mapjson__"network"QueryNetwork.of_jsoninlettransactionId=field_mapjson__"transactionId"QueryTransactionId.of_jsoninlettransactionHash=field_mapjson__"transactionHash"QueryTransactionHash.of_jsoninmake?confirmationStatus?transactionTimestamp?network?transactionId?transactionHash()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container of the transaction output."]moduleValidationExceptionFieldList=structtypenonrect=ValidationExceptionField.tlistletmakei=iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:ValidationExceptionField.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:ValidationExceptionField.of_xml)letof_jsonj=list_of_json~kind:"ValidationExceptionFieldList"~of_json:ValidationExceptionField.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleValidationExceptionReason=structtypenonrect=|UnknownOperation|CannotParse|FieldValidationFailed|Other|Non_static_idofstringletmakei=iletto_string=function|UnknownOperation->"unknownOperation"|CannotParse->"cannotParse"|FieldValidationFailed->"fieldValidationFailed"|Other->"other"|Non_static_ids->sletof_string=function|"unknownOperation"->UnknownOperation|"cannotParse"->CannotParse|"fieldValidationFailed"->FieldValidationFailed|"other"->Other|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ValidationExceptionReason"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ValidationExceptionReason"j)letto_json=simple_to_jsonto_valueendmoduleConfirmationStatusIncludeList=structtypenonrect=ConfirmationStatus.tlistletmakei=letopenResultinok_or_failwith(check_list_mini~min:1);iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:ConfirmationStatus.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:ConfirmationStatus.of_xml)letof_jsonj=list_of_json~kind:"ConfirmationStatusIncludeList"~of_json:ConfirmationStatus.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleListTransactionsSortBy=structtypenonrect=|TRANSACTION_TIMESTAMP|Non_static_idofstringletmakei=iletto_string=function|TRANSACTION_TIMESTAMP->"TRANSACTION_TIMESTAMP"|Non_static_ids->sletof_string=function|"TRANSACTION_TIMESTAMP"->TRANSACTION_TIMESTAMP|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ListTransactionsSortBy"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ListTransactionsSortBy"j)letto_json=simple_to_jsonto_valueendmoduleSortOrder=structtypenonrect=|ASCENDING|DESCENDING|Non_static_idofstringletmakei=iletto_string=function|ASCENDING->"ASCENDING"|DESCENDING->"DESCENDING"|Non_static_ids->sletof_string=function|"ASCENDING"->ASCENDING|"DESCENDING"->DESCENDING|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration SortOrder"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"SortOrder"j)letto_json=simple_to_jsonto_valueendmoduleTransactionEvent=structtypenonrect={network:QueryNetwork.toption[@ocaml.doc"The blockchain network where the transaction occurred."];transactionHash:QueryTransactionHash.toption[@ocaml.doc"The hash of a transaction. It is generated when a transaction is created."];eventType:QueryTransactionEventType.toption[@ocaml.doc"The type of transaction event."];from:ChainAddress.toption[@ocaml.doc"The wallet address initiating the transaction. It can either be a public key or a contract."];to_:ChainAddress.toption[@ocaml.doc"The wallet address receiving the transaction. It can either be a public key or a contract."];value:String_.toption[@ocaml.doc"The value that was transacted."];contractAddress:ChainAddress.toption[@ocaml.doc"The blockchain address for the contract"];tokenId:QueryTokenId.toption[@ocaml.doc"The unique identifier for the token involved in the transaction."];transactionId:String_.toption[@ocaml.doc"The identifier of a Bitcoin transaction. It is generated when a transaction is created."];voutIndex:Integer.toption[@ocaml.doc"The position of the transaction output in the transaction output list."];voutSpent:Boolean.toption[@ocaml.doc"Specifies if the transaction output is spent or unspent. This is only returned for BITCOIN_VOUT event types. This is only returned for BITCOIN_VOUT event types."];spentVoutTransactionId:String_.toption[@ocaml.doc"The transactionId that created the spent transaction output. This is only returned for BITCOIN_VIN event types."];spentVoutTransactionHash:String_.toption[@ocaml.doc"The transactionHash that created the spent transaction output. This is only returned for BITCOIN_VIN event types."];spentVoutIndex:Integer.toption[@ocaml.doc"The position of the spent transaction output in the output list of the creating transaction. This is only returned for BITCOIN_VIN event types."];blockchainInstant:BlockchainInstant.toption;confirmationStatus:ConfirmationStatus.toption[@ocaml.doc"This container specifies whether the transaction has reached Finality."]}letmake?network=fun?transactionHash->fun?eventType->fun?from->fun?to_->fun?value->fun?contractAddress->fun?tokenId->fun?transactionId->fun?voutIndex->fun?voutSpent->fun?spentVoutTransactionId->fun?spentVoutTransactionHash->fun?spentVoutIndex->fun?blockchainInstant->fun?confirmationStatus->fun()->{network;transactionHash;eventType;from;to_;value;contractAddress;tokenId;transactionId;voutIndex;voutSpent;spentVoutTransactionId;spentVoutTransactionHash;spentVoutIndex;blockchainInstant;confirmationStatus}letto_valuex=structure_to_value[("network",(Option.mapx.network~f:QueryNetwork.to_value));("transactionHash",(Option.mapx.transactionHash~f:QueryTransactionHash.to_value));("eventType",(Option.mapx.eventType~f:QueryTransactionEventType.to_value));("from",(Option.mapx.from~f:ChainAddress.to_value));("to",(Option.mapx.to_~f:ChainAddress.to_value));("value",(Option.mapx.value~f:String_.to_value));("contractAddress",(Option.mapx.contractAddress~f:ChainAddress.to_value));("tokenId",(Option.mapx.tokenId~f:QueryTokenId.to_value));("transactionId",(Option.mapx.transactionId~f:String_.to_value));("voutIndex",(Option.mapx.voutIndex~f:Integer.to_value));("voutSpent",(Option.mapx.voutSpent~f:Boolean.to_value));("spentVoutTransactionId",(Option.mapx.spentVoutTransactionId~f:String_.to_value));("spentVoutTransactionHash",(Option.mapx.spentVoutTransactionHash~f:String_.to_value));("spentVoutIndex",(Option.mapx.spentVoutIndex~f:Integer.to_value));("blockchainInstant",(Option.mapx.blockchainInstant~f:BlockchainInstant.to_value));("confirmationStatus",(Option.mapx.confirmationStatus~f:ConfirmationStatus.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letconfirmationStatus=(Option.map~f:ConfirmationStatus.of_xml)(Xml.childxml_arg0"confirmationStatus")inletblockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"blockchainInstant")inletspentVoutIndex=(Option.map~f:Integer.of_xml)(Xml.childxml_arg0"spentVoutIndex")inletspentVoutTransactionHash=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"spentVoutTransactionHash")inletspentVoutTransactionId=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"spentVoutTransactionId")inletvoutSpent=(Option.map~f:Boolean.of_xml)(Xml.childxml_arg0"voutSpent")inletvoutIndex=(Option.map~f:Integer.of_xml)(Xml.childxml_arg0"voutIndex")inlettransactionId=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"transactionId")inlettokenId=(Option.map~f:QueryTokenId.of_xml)(Xml.childxml_arg0"tokenId")inletcontractAddress=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"contractAddress")inletvalue=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"value")inletto_=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"to")inletfrom=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"from")inleteventType=(Option.map~f:QueryTransactionEventType.of_xml)(Xml.childxml_arg0"eventType")inlettransactionHash=(Option.map~f:QueryTransactionHash.of_xml)(Xml.childxml_arg0"transactionHash")inletnetwork=(Option.map~f:QueryNetwork.of_xml)(Xml.childxml_arg0"network")inmake?confirmationStatus?blockchainInstant?spentVoutIndex?spentVoutTransactionHash?spentVoutTransactionId?voutSpent?voutIndex?transactionId?tokenId?contractAddress?value?to_?from?eventType?transactionHash?network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letconfirmationStatus=field_mapjson__"confirmationStatus"ConfirmationStatus.of_jsoninletblockchainInstant=field_mapjson__"blockchainInstant"BlockchainInstant.of_jsoninletspentVoutIndex=field_mapjson__"spentVoutIndex"Integer.of_jsoninletspentVoutTransactionHash=field_mapjson__"spentVoutTransactionHash"String_.of_jsoninletspentVoutTransactionId=field_mapjson__"spentVoutTransactionId"String_.of_jsoninletvoutSpent=field_mapjson__"voutSpent"Boolean.of_jsoninletvoutIndex=field_mapjson__"voutIndex"Integer.of_jsoninlettransactionId=field_mapjson__"transactionId"String_.of_jsoninlettokenId=field_mapjson__"tokenId"QueryTokenId.of_jsoninletcontractAddress=field_mapjson__"contractAddress"ChainAddress.of_jsoninletvalue=field_mapjson__"value"String_.of_jsoninletto_=field_mapjson__"to"ChainAddress.of_jsoninletfrom=field_mapjson__"from"ChainAddress.of_jsoninleteventType=field_mapjson__"eventType"QueryTransactionEventType.of_jsoninlettransactionHash=field_mapjson__"transactionHash"QueryTransactionHash.of_jsoninletnetwork=field_mapjson__"network"QueryNetwork.of_jsoninmake?confirmationStatus?blockchainInstant?spentVoutIndex?spentVoutTransactionHash?spentVoutTransactionId?voutSpent?voutIndex?transactionId?tokenId?contractAddress?value?to_?from?eventType?transactionHash?network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the properties of a transaction event."]moduleTokenBalance=structtypenonrect={ownerIdentifier:OwnerIdentifier.toption[@ocaml.doc"The container for the identifier of the owner."];tokenIdentifier:TokenIdentifier.toption[@ocaml.doc"The identifier for the token, including the unique token ID and its blockchain network."];balance:String_.toption[@ocaml.doc"The container of the token balance."];atBlockchainInstant:BlockchainInstant.toption[@ocaml.doc"The time for when the TokenBalance is requested or the current time if a time is not provided in the request. This time will only be recorded up to the second."];lastUpdatedTime:BlockchainInstant.toption[@ocaml.doc"The Timestamp of the last transaction at which the balance for the token in the wallet was updated."]}letmake?ownerIdentifier=fun?tokenIdentifier->fun?balance->fun?atBlockchainInstant->fun?lastUpdatedTime->fun()->{ownerIdentifier;tokenIdentifier;balance;atBlockchainInstant;lastUpdatedTime}letto_valuex=structure_to_value[("ownerIdentifier",(Option.mapx.ownerIdentifier~f:OwnerIdentifier.to_value));("tokenIdentifier",(Option.mapx.tokenIdentifier~f:TokenIdentifier.to_value));("balance",(Option.mapx.balance~f:String_.to_value));("atBlockchainInstant",(Option.mapx.atBlockchainInstant~f:BlockchainInstant.to_value));("lastUpdatedTime",(Option.mapx.lastUpdatedTime~f:BlockchainInstant.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letlastUpdatedTime=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"lastUpdatedTime")inletatBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"atBlockchainInstant")inletbalance=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"balance")inlettokenIdentifier=(Option.map~f:TokenIdentifier.of_xml)(Xml.childxml_arg0"tokenIdentifier")inletownerIdentifier=(Option.map~f:OwnerIdentifier.of_xml)(Xml.childxml_arg0"ownerIdentifier")inmake?lastUpdatedTime?atBlockchainInstant?balance?tokenIdentifier?ownerIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letlastUpdatedTime=field_mapjson__"lastUpdatedTime"BlockchainInstant.of_jsoninletatBlockchainInstant=field_mapjson__"atBlockchainInstant"BlockchainInstant.of_jsoninletbalance=field_mapjson__"balance"String_.of_jsoninlettokenIdentifier=field_mapjson__"tokenIdentifier"TokenIdentifier.of_jsoninletownerIdentifier=field_mapjson__"ownerIdentifier"OwnerIdentifier.of_jsoninmake?lastUpdatedTime?atBlockchainInstant?balance?tokenIdentifier?ownerIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The balance of the token."]moduleAddressIdentifierFilterTransactionEventToAddressList=structtypenonrect=ChainAddress.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:1)>>=(fun()->check_list_mini~min:1));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:ChainAddress.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:ChainAddress.of_xml)letof_jsonj=list_of_json~kind:"AddressIdentifierFilterTransactionEventToAddressList"~of_json:ChainAddress.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleListFilteredTransactionEventsSortBy=structtypenonrect=|BlockchainInstant|Non_static_idofstringletmakei=iletto_string=function|BlockchainInstant->"blockchainInstant"|Non_static_ids->sletof_string=function|"blockchainInstant"->BlockchainInstant|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ListFilteredTransactionEventsSortBy"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ListFilteredTransactionEventsSortBy"j)letto_json=simple_to_jsonto_valueendmoduleAssetContract=structtypenonrect={contractIdentifier:ContractIdentifier.toption[@ocaml.doc"The container for the contract identifier containing its blockchain network and address."];tokenStandard:QueryTokenStandard.toption[@ocaml.doc"The token standard of the contract."];deployerAddress:ChainAddress.toption[@ocaml.doc"The address of the contract deployer."]}letmake?contractIdentifier=fun?tokenStandard->fun?deployerAddress->fun()->{contractIdentifier;tokenStandard;deployerAddress}letto_valuex=structure_to_value[("contractIdentifier",(Option.mapx.contractIdentifier~f:ContractIdentifier.to_value));("tokenStandard",(Option.mapx.tokenStandard~f:QueryTokenStandard.to_value));("deployerAddress",(Option.mapx.deployerAddress~f:ChainAddress.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letdeployerAddress=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"deployerAddress")inlettokenStandard=(Option.map~f:QueryTokenStandard.of_xml)(Xml.childxml_arg0"tokenStandard")inletcontractIdentifier=(Option.map~f:ContractIdentifier.of_xml)(Xml.childxml_arg0"contractIdentifier")inmake?deployerAddress?tokenStandard?contractIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letdeployerAddress=field_mapjson__"deployerAddress"ChainAddress.of_jsoninlettokenStandard=field_mapjson__"tokenStandard"QueryTokenStandard.of_jsoninletcontractIdentifier=field_mapjson__"contractIdentifier"ContractIdentifier.of_jsoninmake?deployerAddress?tokenStandard?contractIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"This container contains information about an contract."]moduleBlockHash=structtypenonrect=stringletcontext_="BlockHash"letmakei=letopenResultinok_or_failwith(check_patterni~pattern:"(0x[A-Fa-f0-9]{64}|[A-Fa-f0-9]{64})");iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"BlockHash"jletto_json=simple_to_jsonto_valueendmoduleExecutionStatus=structtypenonrect=|FAILED|SUCCEEDED|Non_static_idofstringletmakei=iletto_string=function|FAILED->"FAILED"|SUCCEEDED->"SUCCEEDED"|Non_static_ids->sletof_string=function|"FAILED"->FAILED|"SUCCEEDED"->SUCCEEDED|x->Non_static_idxletto_valuex=`Enum(to_stringx)letto_queryv=to_queryto_valuevletto_headerx=to_stringxletof_xmlxml_arg0=of_string(string_of_xml~kind:"enumeration ExecutionStatus"xml_arg0)letof_jsonj=of_string(string_of_json~kind:"ExecutionStatus"j)letto_json=simple_to_jsonto_valueendmoduleLong=structtypenonrect=Int64.tletmakei=iletof_string=Int64.of_stringletto_valuex=`Longxletto_queryv=to_queryto_valuevletto_headerx=Int64.to_stringxletof_xmlxml_arg0=Int64.of_string(string_of_xml~kind:"a long"xml_arg0)letof_jsonj=Int64.of_float(float_of_json~kind:"a long"j)letto_json=simple_to_jsonto_valueendmoduleBatchGetTokenBalanceErrorItem=structtypenonrect={tokenIdentifier:TokenIdentifier.toption;ownerIdentifier:OwnerIdentifier.toption;atBlockchainInstant:BlockchainInstant.toption;errorCode:String_.toption[@ocaml.doc"The error code associated with the error."];errorMessage:String_.toption[@ocaml.doc"The message associated with the error."];errorType:ErrorType.toption[@ocaml.doc"The type of error."]}letmake?tokenIdentifier=fun?ownerIdentifier->fun?atBlockchainInstant->fun?errorCode->fun?errorMessage->fun?errorType->fun()->{tokenIdentifier;ownerIdentifier;atBlockchainInstant;errorCode;errorMessage;errorType}letto_valuex=structure_to_value[("tokenIdentifier",(Option.mapx.tokenIdentifier~f:TokenIdentifier.to_value));("ownerIdentifier",(Option.mapx.ownerIdentifier~f:OwnerIdentifier.to_value));("atBlockchainInstant",(Option.mapx.atBlockchainInstant~f:BlockchainInstant.to_value));("errorCode",(Option.mapx.errorCode~f:String_.to_value));("errorMessage",(Option.mapx.errorMessage~f:String_.to_value));("errorType",(Option.mapx.errorType~f:ErrorType.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=leterrorType=(Option.map~f:ErrorType.of_xml)(Xml.childxml_arg0"errorType")inleterrorMessage=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"errorMessage")inleterrorCode=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"errorCode")inletatBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"atBlockchainInstant")inletownerIdentifier=(Option.map~f:OwnerIdentifier.of_xml)(Xml.childxml_arg0"ownerIdentifier")inlettokenIdentifier=(Option.map~f:TokenIdentifier.of_xml)(Xml.childxml_arg0"tokenIdentifier")inmake?errorType?errorMessage?errorCode?atBlockchainInstant?ownerIdentifier?tokenIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=leterrorType=field_mapjson__"errorType"ErrorType.of_jsoninleterrorMessage=field_mapjson__"errorMessage"String_.of_jsoninleterrorCode=field_mapjson__"errorCode"String_.of_jsoninletatBlockchainInstant=field_mapjson__"atBlockchainInstant"BlockchainInstant.of_jsoninletownerIdentifier=field_mapjson__"ownerIdentifier"OwnerIdentifier.of_jsoninlettokenIdentifier=field_mapjson__"tokenIdentifier"TokenIdentifier.of_jsoninmake?errorType?errorMessage?errorCode?atBlockchainInstant?ownerIdentifier?tokenIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Error generated from a failed BatchGetTokenBalance request."]moduleBatchGetTokenBalanceOutputItem=structtypenonrect={ownerIdentifier:OwnerIdentifier.toption;tokenIdentifier:TokenIdentifier.toption;balance:String_.toption[@ocaml.doc"The container for the token balance."];atBlockchainInstant:BlockchainInstant.toption;lastUpdatedTime:BlockchainInstant.toption}letmake?ownerIdentifier=fun?tokenIdentifier->fun?balance->fun?atBlockchainInstant->fun?lastUpdatedTime->fun()->{ownerIdentifier;tokenIdentifier;balance;atBlockchainInstant;lastUpdatedTime}letto_valuex=structure_to_value[("ownerIdentifier",(Option.mapx.ownerIdentifier~f:OwnerIdentifier.to_value));("tokenIdentifier",(Option.mapx.tokenIdentifier~f:TokenIdentifier.to_value));("balance",(Option.mapx.balance~f:String_.to_value));("atBlockchainInstant",(Option.mapx.atBlockchainInstant~f:BlockchainInstant.to_value));("lastUpdatedTime",(Option.mapx.lastUpdatedTime~f:BlockchainInstant.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letlastUpdatedTime=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"lastUpdatedTime")inletatBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"atBlockchainInstant")inletbalance=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"balance")inlettokenIdentifier=(Option.map~f:TokenIdentifier.of_xml)(Xml.childxml_arg0"tokenIdentifier")inletownerIdentifier=(Option.map~f:OwnerIdentifier.of_xml)(Xml.childxml_arg0"ownerIdentifier")inmake?lastUpdatedTime?atBlockchainInstant?balance?tokenIdentifier?ownerIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letlastUpdatedTime=field_mapjson__"lastUpdatedTime"BlockchainInstant.of_jsoninletatBlockchainInstant=field_mapjson__"atBlockchainInstant"BlockchainInstant.of_jsoninletbalance=field_mapjson__"balance"String_.of_jsoninlettokenIdentifier=field_mapjson__"tokenIdentifier"TokenIdentifier.of_jsoninletownerIdentifier=field_mapjson__"ownerIdentifier"OwnerIdentifier.of_jsoninmake?lastUpdatedTime?atBlockchainInstant?balance?tokenIdentifier?ownerIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the properties of a token balance output."]moduleBatchGetTokenBalanceInputItem=structtypenonrect={tokenIdentifier:TokenIdentifier.t;ownerIdentifier:OwnerIdentifier.t;atBlockchainInstant:BlockchainInstant.toption}letcontext_="BatchGetTokenBalanceInputItem"letmake?atBlockchainInstant=fun~tokenIdentifier->fun~ownerIdentifier->fun()->{atBlockchainInstant;tokenIdentifier;ownerIdentifier}letto_valuex=structure_to_value[("tokenIdentifier",(Some(TokenIdentifier.to_valuex.tokenIdentifier)));("ownerIdentifier",(Some(OwnerIdentifier.to_valuex.ownerIdentifier)));("atBlockchainInstant",(Option.mapx.atBlockchainInstant~f:BlockchainInstant.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letatBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"atBlockchainInstant")inletownerIdentifier=OwnerIdentifier.of_xml(Xml.child_exn~context:context_xml_arg0"ownerIdentifier")inlettokenIdentifier=TokenIdentifier.of_xml(Xml.child_exn~context:context_xml_arg0"tokenIdentifier")inmake?atBlockchainInstant~ownerIdentifier~tokenIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letatBlockchainInstant=field_mapjson__"atBlockchainInstant"BlockchainInstant.of_jsoninletownerIdentifier=field_map_exnjson__"ownerIdentifier"OwnerIdentifier.of_jsoninlettokenIdentifier=field_map_exnjson__"tokenIdentifier"TokenIdentifier.of_jsoninmake?atBlockchainInstant~ownerIdentifier~tokenIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the input for getting a token balance."]moduleAccessDeniedException=structtypenonrect={message:ExceptionMessage.toption[@ocaml.doc"The container for the exception message."]}letmake?message=fun()->{message}letto_valuex=structure_to_value[("message",(Option.mapx.message~f:ExceptionMessage.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmessage=(Option.map~f:ExceptionMessage.of_xml)(Xml.childxml_arg0"message")inmake?message()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmessage=field_mapjson__"message"ExceptionMessage.of_jsoninmake?message()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The Amazon Web Services account doesn\226\128\153t have access to this resource."]moduleInternalServerException=structtypenonrect={message:ExceptionMessage.toption[@ocaml.doc"The container for the exception message."];retryAfterSeconds:Integer.toption[@ocaml.doc"Specifies the retryAfterSeconds value."]}letmake?message=fun?retryAfterSeconds->fun()->{message;retryAfterSeconds}letto_valuex=structure_to_value[("message",(Option.mapx.message~f:ExceptionMessage.to_value));("Retry-After",(Option.mapx.retryAfterSeconds~f:Integer.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letretryAfterSeconds=(Option.map~f:Integer.of_xml)(Xml.childxml_arg0"Retry-After")inletmessage=(Option.map~f:ExceptionMessage.of_xml)(Xml.childxml_arg0"message")inmake?retryAfterSeconds?message()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letretryAfterSeconds=field_mapjson__"retryAfterSeconds"Integer.of_jsoninletmessage=field_mapjson__"message"ExceptionMessage.of_jsoninmake?retryAfterSeconds?message()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The request processing has failed because of an internal error in the service."]moduleNextToken=structtypenonrect=stringletcontext_="NextToken"letmakei=letopenResultinok_or_failwith((check_string_maxi~max:131070)>>=(fun()->check_string_mini~min:0));iletof_stringx=xletto_valuex=`Stringxletto_queryv=to_queryto_valuevletto_headerx=xletof_xml=Xml.string_data_exn~context:context_letof_jsonj=string_of_json~kind:"NextToken"jletto_json=simple_to_jsonto_valueendmoduleServiceQuotaExceededException=structtypenonrect={message:ExceptionMessage.toption[@ocaml.doc"The container for the exception message."];resourceId:ResourceId.toption[@ocaml.doc"The resourceId of the resource that caused the exception."];resourceType:ResourceType.toption[@ocaml.doc"The resourceType of the resource that caused the exception."];serviceCode:ServiceCode.toption[@ocaml.doc"The container for the serviceCode."];quotaCode:QuotaCode.toption[@ocaml.doc"The container for the quotaCode."]}letmake?message=fun?resourceId->fun?resourceType->fun?serviceCode->fun?quotaCode->fun()->{message;resourceId;resourceType;serviceCode;quotaCode}letto_valuex=structure_to_value[("message",(Option.mapx.message~f:ExceptionMessage.to_value));("resourceId",(Option.mapx.resourceId~f:ResourceId.to_value));("resourceType",(Option.mapx.resourceType~f:ResourceType.to_value));("serviceCode",(Option.mapx.serviceCode~f:ServiceCode.to_value));("quotaCode",(Option.mapx.quotaCode~f:QuotaCode.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letquotaCode=(Option.map~f:QuotaCode.of_xml)(Xml.childxml_arg0"quotaCode")inletserviceCode=(Option.map~f:ServiceCode.of_xml)(Xml.childxml_arg0"serviceCode")inletresourceType=(Option.map~f:ResourceType.of_xml)(Xml.childxml_arg0"resourceType")inletresourceId=(Option.map~f:ResourceId.of_xml)(Xml.childxml_arg0"resourceId")inletmessage=(Option.map~f:ExceptionMessage.of_xml)(Xml.childxml_arg0"message")inmake?quotaCode?serviceCode?resourceType?resourceId?message()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letquotaCode=field_mapjson__"quotaCode"QuotaCode.of_jsoninletserviceCode=field_mapjson__"serviceCode"ServiceCode.of_jsoninletresourceType=field_mapjson__"resourceType"ResourceType.of_jsoninletresourceId=field_mapjson__"resourceId"ResourceId.of_jsoninletmessage=field_mapjson__"message"ExceptionMessage.of_jsoninmake?quotaCode?serviceCode?resourceType?resourceId?message()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The service quota has been exceeded for this resource."]moduleThrottlingException=structtypenonrect={message:ExceptionMessage.toption[@ocaml.doc"The container for the exception message."];serviceCode:ServiceCode.toption[@ocaml.doc"The container for the serviceCode."];quotaCode:QuotaCode.toption[@ocaml.doc"The container for the quotaCode."];retryAfterSeconds:Integer.toption[@ocaml.doc"The container of the retryAfterSeconds value."]}letmake?message=fun?serviceCode->fun?quotaCode->fun?retryAfterSeconds->fun()->{message;serviceCode;quotaCode;retryAfterSeconds}letto_valuex=structure_to_value[("message",(Option.mapx.message~f:ExceptionMessage.to_value));("serviceCode",(Option.mapx.serviceCode~f:ServiceCode.to_value));("quotaCode",(Option.mapx.quotaCode~f:QuotaCode.to_value));("Retry-After",(Option.mapx.retryAfterSeconds~f:Integer.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letretryAfterSeconds=(Option.map~f:Integer.of_xml)(Xml.childxml_arg0"Retry-After")inletquotaCode=(Option.map~f:QuotaCode.of_xml)(Xml.childxml_arg0"quotaCode")inletserviceCode=(Option.map~f:ServiceCode.of_xml)(Xml.childxml_arg0"serviceCode")inletmessage=(Option.map~f:ExceptionMessage.of_xml)(Xml.childxml_arg0"message")inmake?retryAfterSeconds?quotaCode?serviceCode?message()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letretryAfterSeconds=field_mapjson__"retryAfterSeconds"Integer.of_jsoninletquotaCode=field_mapjson__"quotaCode"QuotaCode.of_jsoninletserviceCode=field_mapjson__"serviceCode"ServiceCode.of_jsoninletmessage=field_mapjson__"message"ExceptionMessage.of_jsoninmake?retryAfterSeconds?quotaCode?serviceCode?message()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The request or operation couldn't be performed because a service is throttling requests. The most common source of throttling errors is when you create resources that exceed your service limit for this resource type. Request a limit increase or delete unused resources, if possible."]moduleTransactionOutputList=structtypenonrect=TransactionOutputItem.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:250)>>=(fun()->check_list_mini~min:0));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:TransactionOutputItem.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:TransactionOutputItem.of_xml)letof_jsonj=list_of_json~kind:"TransactionOutputList"~of_json:TransactionOutputItem.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleValidationException=structtypenonrect={message:ExceptionMessage.toption[@ocaml.doc"The container for the exception message."];reason:ValidationExceptionReason.toption[@ocaml.doc"The container for the reason for the exception"];fieldList:ValidationExceptionFieldList.toption[@ocaml.doc"The container for the fieldList of the exception."]}letmake?message=fun?reason->fun?fieldList->fun()->{message;reason;fieldList}letto_valuex=structure_to_value[("message",(Option.mapx.message~f:ExceptionMessage.to_value));("reason",(Option.mapx.reason~f:ValidationExceptionReason.to_value));("fieldList",(Option.mapx.fieldList~f:ValidationExceptionFieldList.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letfieldList=(Option.map~f:ValidationExceptionFieldList.of_xml)(Xml.childxml_arg0"fieldList")inletreason=(Option.map~f:ValidationExceptionReason.of_xml)(Xml.childxml_arg0"reason")inletmessage=(Option.map~f:ExceptionMessage.of_xml)(Xml.childxml_arg0"message")inmake?fieldList?reason?message()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letfieldList=field_mapjson__"fieldList"ValidationExceptionFieldList.of_jsoninletreason=field_mapjson__"reason"ValidationExceptionReason.of_jsoninletmessage=field_mapjson__"message"ExceptionMessage.of_jsoninmake?fieldList?reason?message()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The resource passed is invalid."]moduleConfirmationStatusFilter=structtypenonrect={include_:ConfirmationStatusIncludeList.t[@ocaml.doc"The container to determine whether to list results that have only reached finality . Transactions that have reached finality are always part of the response."]}letcontext_="ConfirmationStatusFilter"letmake~include_=fun()->{include_}letto_valuex=structure_to_value[("include",(Some(ConfirmationStatusIncludeList.to_valuex.include_)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letinclude_=ConfirmationStatusIncludeList.of_xml(Xml.child_exn~context:context_xml_arg0"include")inmake~include_()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letinclude_=field_map_exnjson__"include"ConfirmationStatusIncludeList.of_jsoninmake~include_()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the ConfirmationStatusFilter that filters for the finality of the results."]moduleListTransactionsInputMaxResultsInteger=structtypenonrect=intletmakei=letopenResultinok_or_failwith((check_int_maxi~max:250)>>=(fun()->check_int_mini~min:1));iletof_string=Int.of_stringletto_valuex=`Integerxletto_queryv=to_queryto_valuevletto_headerx=Int.to_stringxletof_xmlxml_arg0=Int.of_string(string_of_xml~kind:"an integer for ListTransactionsInputMaxResultsInteger"xml_arg0)letof_jsonj=Int.of_float(float_of_json~kind:"an integer"j)letto_json=simple_to_jsonto_valueendmoduleListTransactionsSort=structtypenonrect={sortBy:ListTransactionsSortBy.toption[@ocaml.doc"Defaults to the value TRANSACTION_TIMESTAMP."];sortOrder:SortOrder.toption[@ocaml.doc"The container for the sort order for ListTransactions. The SortOrder field only accepts the values ASCENDING and DESCENDING. Not providing SortOrder will default to ASCENDING."]}letmake?sortBy=fun?sortOrder->fun()->{sortBy;sortOrder}letto_valuex=structure_to_value[("sortBy",(Option.mapx.sortBy~f:ListTransactionsSortBy.to_value));("sortOrder",(Option.mapx.sortOrder~f:SortOrder.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letsortOrder=(Option.map~f:SortOrder.of_xml)(Xml.childxml_arg0"sortOrder")inletsortBy=(Option.map~f:ListTransactionsSortBy.of_xml)(Xml.childxml_arg0"sortBy")inmake?sortOrder?sortBy()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letsortOrder=field_mapjson__"sortOrder"SortOrder.of_jsoninletsortBy=field_mapjson__"sortBy"ListTransactionsSortBy.of_jsoninmake?sortOrder?sortBy()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for determining how the list transaction result will be sorted."]moduleTransactionEventList=structtypenonrect=TransactionEvent.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:250)>>=(fun()->check_list_mini~min:0));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:TransactionEvent.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:TransactionEvent.of_xml)letof_jsonj=list_of_json~kind:"TransactionEventList"~of_json:TransactionEvent.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleListTransactionEventsInputMaxResultsInteger=structtypenonrect=intletmakei=letopenResultinok_or_failwith((check_int_maxi~max:250)>>=(fun()->check_int_mini~min:1));iletof_string=Int.of_stringletto_valuex=`Integerxletto_queryv=to_queryto_valuevletto_headerx=Int.to_stringxletof_xmlxml_arg0=Int.of_string(string_of_xml~kind:"an integer for ListTransactionEventsInputMaxResultsInteger"xml_arg0)letof_jsonj=Int.of_float(float_of_json~kind:"an integer"j)letto_json=simple_to_jsonto_valueendmoduleTokenBalanceList=structtypenonrect=TokenBalance.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:250)>>=(fun()->check_list_mini~min:0));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:TokenBalance.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:TokenBalance.of_xml)letof_jsonj=list_of_json~kind:"TokenBalanceList"~of_json:TokenBalance.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleListTokenBalancesInputMaxResultsInteger=structtypenonrect=intletmakei=letopenResultinok_or_failwith((check_int_maxi~max:250)>>=(fun()->check_int_mini~min:1));iletof_string=Int.of_stringletto_valuex=`Integerxletto_queryv=to_queryto_valuevletto_headerx=Int.to_stringxletof_xmlxml_arg0=Int.of_string(string_of_xml~kind:"an integer for ListTokenBalancesInputMaxResultsInteger"xml_arg0)letof_jsonj=Int.of_float(float_of_json~kind:"an integer"j)letto_json=simple_to_jsonto_valueendmoduleOwnerFilter=structtypenonrect={address:ChainAddress.t[@ocaml.doc"The contract or wallet address."]}letcontext_="OwnerFilter"letmake~address=fun()->{address}letto_valuex=structure_to_value[("address",(Some(ChainAddress.to_valuex.address)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letaddress=ChainAddress.of_xml(Xml.child_exn~context:context_xml_arg0"address")inmake~address()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letaddress=field_map_exnjson__"address"ChainAddress.of_jsoninmake~address()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container for the owner information to filter by."]moduleTokenFilter=structtypenonrect={network:QueryNetwork.t[@ocaml.doc"The blockchain network of the token."];contractAddress:ChainAddress.toption[@ocaml.doc"This is the address of the contract."];tokenId:QueryTokenId.toption[@ocaml.doc"The unique identifier of the token."]}letcontext_="TokenFilter"letmake?contractAddress=fun?tokenId->fun~network->fun()->{contractAddress;tokenId;network}letto_valuex=structure_to_value[("network",(Some(QueryNetwork.to_valuex.network)));("contractAddress",(Option.mapx.contractAddress~f:ChainAddress.to_value));("tokenId",(Option.mapx.tokenId~f:QueryTokenId.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=lettokenId=(Option.map~f:QueryTokenId.of_xml)(Xml.childxml_arg0"tokenId")inletcontractAddress=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"contractAddress")inletnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inmake?tokenId?contractAddress~network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=lettokenId=field_mapjson__"tokenId"QueryTokenId.of_jsoninletcontractAddress=field_mapjson__"contractAddress"ChainAddress.of_jsoninletnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninmake?tokenId?contractAddress~network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The container of the token filter like the contract address on a given blockchain network or a unique token identifier on a given blockchain network. You must always specify the network property of this container when using this operation."]moduleAddressIdentifierFilter=structtypenonrect={transactionEventToAddress:AddressIdentifierFilterTransactionEventToAddressList.t[@ocaml.doc"The container for the recipient address of the transaction."]}letcontext_="AddressIdentifierFilter"letmake~transactionEventToAddress=fun()->{transactionEventToAddress}letto_valuex=structure_to_value[("transactionEventToAddress",(Some(AddressIdentifierFilterTransactionEventToAddressList.to_valuex.transactionEventToAddress)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=lettransactionEventToAddress=AddressIdentifierFilterTransactionEventToAddressList.of_xml(Xml.child_exn~context:context_xml_arg0"transactionEventToAddress")inmake~transactionEventToAddress()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=lettransactionEventToAddress=field_map_exnjson__"transactionEventToAddress"AddressIdentifierFilterTransactionEventToAddressList.of_jsoninmake~transactionEventToAddress()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"This is the container for the unique public address on the blockchain."]moduleListFilteredTransactionEventsInputMaxResultsInteger=structtypenonrect=intletmakei=letopenResultinok_or_failwith((check_int_maxi~max:250)>>=(fun()->check_int_mini~min:1));iletof_string=Int.of_stringletto_valuex=`Integerxletto_queryv=to_queryto_valuevletto_headerx=Int.to_stringxletof_xmlxml_arg0=Int.of_string(string_of_xml~kind:"an integer for ListFilteredTransactionEventsInputMaxResultsInteger"xml_arg0)letof_jsonj=Int.of_float(float_of_json~kind:"an integer"j)letto_json=simple_to_jsonto_valueendmoduleListFilteredTransactionEventsSort=structtypenonrect={sortBy:ListFilteredTransactionEventsSortBy.toption[@ocaml.doc"Container on how the results will be sorted by?"];sortOrder:SortOrder.toption[@ocaml.doc"The container for the sort order for ListFilteredTransactionEvents. The SortOrder field only accepts the values ASCENDING and DESCENDING. Not providing SortOrder will default to ASCENDING."]}letmake?sortBy=fun?sortOrder->fun()->{sortBy;sortOrder}letto_valuex=structure_to_value[("sortBy",(Option.mapx.sortBy~f:ListFilteredTransactionEventsSortBy.to_value));("sortOrder",(Option.mapx.sortOrder~f:SortOrder.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letsortOrder=(Option.map~f:SortOrder.of_xml)(Xml.childxml_arg0"sortOrder")inletsortBy=(Option.map~f:ListFilteredTransactionEventsSortBy.of_xml)(Xml.childxml_arg0"sortBy")inmake?sortOrder?sortBy()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letsortOrder=field_mapjson__"sortOrder"SortOrder.of_jsoninletsortBy=field_mapjson__"sortBy"ListFilteredTransactionEventsSortBy.of_jsoninmake?sortOrder?sortBy()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for an address on the blockchain. This operation is only supported on the Bitcoin blockchain networks."]moduleTimeFilter=structtypenonrect={from:BlockchainInstant.toption;to_:BlockchainInstant.toption}letmake?from=fun?to_->fun()->{from;to_}letto_valuex=structure_to_value[("from",(Option.mapx.from~f:BlockchainInstant.to_value));("to",(Option.mapx.to_~f:BlockchainInstant.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letto_=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"to")inletfrom=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"from")inmake?to_?from()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letto_=field_mapjson__"to"BlockchainInstant.of_jsoninletfrom=field_mapjson__"from"BlockchainInstant.of_jsoninmake?to_?from()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"This container is used to specify a time frame."]moduleVoutFilter=structtypenonrect={voutSpent:Boolean.t[@ocaml.doc"Specifies if the transaction output is spent or unspent."]}letcontext_="VoutFilter"letmake~voutSpent=fun()->{voutSpent}letto_valuex=structure_to_value[("voutSpent",(Some(Boolean.to_valuex.voutSpent)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letvoutSpent=Boolean.of_xml(Xml.child_exn~context:context_xml_arg0"voutSpent")inmake~voutSpent()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letvoutSpent=field_map_exnjson__"voutSpent"Boolean.of_jsoninmake~voutSpent()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"This container specifies filtering attributes related to BITCOIN_VOUT event types"]moduleAssetContractList=structtypenonrect=AssetContract.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:250)>>=(fun()->check_list_mini~min:0));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:AssetContract.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:AssetContract.of_xml)letof_jsonj=list_of_json~kind:"AssetContractList"~of_json:AssetContract.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleContractFilter=structtypenonrect={network:QueryNetwork.t[@ocaml.doc"The blockchain network of the contract."];tokenStandard:QueryTokenStandard.t[@ocaml.doc"The container for the token standard."];deployerAddress:ChainAddress.t[@ocaml.doc"The network address of the deployer."]}letcontext_="ContractFilter"letmake~network=fun~tokenStandard->fun~deployerAddress->fun()->{network;tokenStandard;deployerAddress}letto_valuex=structure_to_value[("network",(Some(QueryNetwork.to_valuex.network)));("tokenStandard",(Some(QueryTokenStandard.to_valuex.tokenStandard)));("deployerAddress",(Some(ChainAddress.to_valuex.deployerAddress)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letdeployerAddress=ChainAddress.of_xml(Xml.child_exn~context:context_xml_arg0"deployerAddress")inlettokenStandard=QueryTokenStandard.of_xml(Xml.child_exn~context:context_xml_arg0"tokenStandard")inletnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inmake~deployerAddress~tokenStandard~network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letdeployerAddress=field_map_exnjson__"deployerAddress"ChainAddress.of_jsoninlettokenStandard=field_map_exnjson__"tokenStandard"QueryTokenStandard.of_jsoninletnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninmake~deployerAddress~tokenStandard~network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The contract or wallet address by which to filter the request."]moduleListAssetContractsInputMaxResultsInteger=structtypenonrect=intletmakei=letopenResultinok_or_failwith((check_int_maxi~max:250)>>=(fun()->check_int_mini~min:1));iletof_string=Int.of_stringletto_valuex=`Integerxletto_queryv=to_queryto_valuevletto_headerx=Int.to_stringxletof_xmlxml_arg0=Int.of_string(string_of_xml~kind:"an integer for ListAssetContractsInputMaxResultsInteger"xml_arg0)letof_jsonj=Int.of_float(float_of_json~kind:"an integer"j)letto_json=simple_to_jsonto_valueendmoduleResourceNotFoundException=structtypenonrect={message:ExceptionMessage.toption[@ocaml.doc"The container for the exception message."];resourceId:ResourceId.toption[@ocaml.doc"The resourceId of the resource that caused the exception."];resourceType:ResourceType.toption[@ocaml.doc"The resourceType of the resource that caused the exception."]}letmake?message=fun?resourceId->fun?resourceType->fun()->{message;resourceId;resourceType}letto_valuex=structure_to_value[("message",(Option.mapx.message~f:ExceptionMessage.to_value));("resourceId",(Option.mapx.resourceId~f:ResourceId.to_value));("resourceType",(Option.mapx.resourceType~f:ResourceType.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letresourceType=(Option.map~f:ResourceType.of_xml)(Xml.childxml_arg0"resourceType")inletresourceId=(Option.map~f:ResourceId.of_xml)(Xml.childxml_arg0"resourceId")inletmessage=(Option.map~f:ExceptionMessage.of_xml)(Xml.childxml_arg0"message")inmake?resourceType?resourceId?message()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letresourceType=field_mapjson__"resourceType"ResourceType.of_jsoninletresourceId=field_mapjson__"resourceId"ResourceId.of_jsoninletmessage=field_mapjson__"message"ExceptionMessage.of_jsoninmake?resourceType?resourceId?message()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The resource was not found."]moduleTransaction=structtypenonrect={network:QueryNetwork.toption[@ocaml.doc"The blockchain network where the transaction occurred."];blockHash:BlockHash.toption[@ocaml.doc"The block hash is a unique identifier for a block. It is a fixed-size string that is calculated by using the information in the block. The block hash is used to verify the integrity of the data in the block."];transactionHash:QueryTransactionHash.toption[@ocaml.doc"The hash of a transaction. It is generated when a transaction is created."];blockNumber:String_.toption[@ocaml.doc"The block number in which the transaction is recorded."];transactionTimestamp:Timestamp.toption[@ocaml.doc"The Timestamp of the transaction."];transactionIndex:Long.toption[@ocaml.doc"The index of the transaction within a blockchain."];numberOfTransactions:Long.toption[@ocaml.doc"The number of transactions in the block."];to_:ChainAddress.toption[@ocaml.doc"The identifier of the transaction. It is generated whenever a transaction is verified and added to the blockchain."];from:ChainAddress.toption[@ocaml.doc"The initiator of the transaction. It is either in the form a public key or a contract address."];contractAddress:ChainAddress.toption[@ocaml.doc"The blockchain address for the contract."];gasUsed:String_.toption[@ocaml.doc"The amount of gas used for the transaction."];cumulativeGasUsed:String_.toption[@ocaml.doc"The amount of gas used up to the specified point in the block."];effectiveGasPrice:String_.toption[@ocaml.doc"The effective gas price."];signatureV:Integer.toption[@ocaml.doc"The signature of the transaction. The Z coordinate of a point V."];signatureR:String_.toption[@ocaml.doc"The signature of the transaction. The X coordinate of a point R."];signatureS:String_.toption[@ocaml.doc"The signature of the transaction. The Y coordinate of a point S."];transactionFee:String_.toption[@ocaml.doc"The transaction fee."];transactionId:String_.toption[@ocaml.doc"The identifier of a Bitcoin transaction. It is generated when a transaction is created."];confirmationStatus:ConfirmationStatus.toption[@ocaml.doc"Specifies whether the transaction has reached Finality."];executionStatus:ExecutionStatus.toption[@ocaml.doc"Identifies whether the transaction has succeeded or failed."]}letmake?network=fun?blockHash->fun?transactionHash->fun?blockNumber->fun?transactionTimestamp->fun?transactionIndex->fun?numberOfTransactions->fun?to_->fun?from->fun?contractAddress->fun?gasUsed->fun?cumulativeGasUsed->fun?effectiveGasPrice->fun?signatureV->fun?signatureR->fun?signatureS->fun?transactionFee->fun?transactionId->fun?confirmationStatus->fun?executionStatus->fun()->{network;blockHash;transactionHash;blockNumber;transactionTimestamp;transactionIndex;numberOfTransactions;to_;from;contractAddress;gasUsed;cumulativeGasUsed;effectiveGasPrice;signatureV;signatureR;signatureS;transactionFee;transactionId;confirmationStatus;executionStatus}letto_valuex=structure_to_value[("network",(Option.mapx.network~f:QueryNetwork.to_value));("blockHash",(Option.mapx.blockHash~f:BlockHash.to_value));("transactionHash",(Option.mapx.transactionHash~f:QueryTransactionHash.to_value));("blockNumber",(Option.mapx.blockNumber~f:String_.to_value));("transactionTimestamp",(Option.mapx.transactionTimestamp~f:Timestamp.to_value));("transactionIndex",(Option.mapx.transactionIndex~f:Long.to_value));("numberOfTransactions",(Option.mapx.numberOfTransactions~f:Long.to_value));("to",(Option.mapx.to_~f:ChainAddress.to_value));("from",(Option.mapx.from~f:ChainAddress.to_value));("contractAddress",(Option.mapx.contractAddress~f:ChainAddress.to_value));("gasUsed",(Option.mapx.gasUsed~f:String_.to_value));("cumulativeGasUsed",(Option.mapx.cumulativeGasUsed~f:String_.to_value));("effectiveGasPrice",(Option.mapx.effectiveGasPrice~f:String_.to_value));("signatureV",(Option.mapx.signatureV~f:Integer.to_value));("signatureR",(Option.mapx.signatureR~f:String_.to_value));("signatureS",(Option.mapx.signatureS~f:String_.to_value));("transactionFee",(Option.mapx.transactionFee~f:String_.to_value));("transactionId",(Option.mapx.transactionId~f:String_.to_value));("confirmationStatus",(Option.mapx.confirmationStatus~f:ConfirmationStatus.to_value));("executionStatus",(Option.mapx.executionStatus~f:ExecutionStatus.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letexecutionStatus=(Option.map~f:ExecutionStatus.of_xml)(Xml.childxml_arg0"executionStatus")inletconfirmationStatus=(Option.map~f:ConfirmationStatus.of_xml)(Xml.childxml_arg0"confirmationStatus")inlettransactionId=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"transactionId")inlettransactionFee=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"transactionFee")inletsignatureS=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"signatureS")inletsignatureR=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"signatureR")inletsignatureV=(Option.map~f:Integer.of_xml)(Xml.childxml_arg0"signatureV")inleteffectiveGasPrice=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"effectiveGasPrice")inletcumulativeGasUsed=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"cumulativeGasUsed")inletgasUsed=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"gasUsed")inletcontractAddress=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"contractAddress")inletfrom=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"from")inletto_=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"to")inletnumberOfTransactions=(Option.map~f:Long.of_xml)(Xml.childxml_arg0"numberOfTransactions")inlettransactionIndex=(Option.map~f:Long.of_xml)(Xml.childxml_arg0"transactionIndex")inlettransactionTimestamp=(Option.map~f:Timestamp.of_xml)(Xml.childxml_arg0"transactionTimestamp")inletblockNumber=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"blockNumber")inlettransactionHash=(Option.map~f:QueryTransactionHash.of_xml)(Xml.childxml_arg0"transactionHash")inletblockHash=(Option.map~f:BlockHash.of_xml)(Xml.childxml_arg0"blockHash")inletnetwork=(Option.map~f:QueryNetwork.of_xml)(Xml.childxml_arg0"network")inmake?executionStatus?confirmationStatus?transactionId?transactionFee?signatureS?signatureR?signatureV?effectiveGasPrice?cumulativeGasUsed?gasUsed?contractAddress?from?to_?numberOfTransactions?transactionIndex?transactionTimestamp?blockNumber?transactionHash?blockHash?network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letexecutionStatus=field_mapjson__"executionStatus"ExecutionStatus.of_jsoninletconfirmationStatus=field_mapjson__"confirmationStatus"ConfirmationStatus.of_jsoninlettransactionId=field_mapjson__"transactionId"String_.of_jsoninlettransactionFee=field_mapjson__"transactionFee"String_.of_jsoninletsignatureS=field_mapjson__"signatureS"String_.of_jsoninletsignatureR=field_mapjson__"signatureR"String_.of_jsoninletsignatureV=field_mapjson__"signatureV"Integer.of_jsoninleteffectiveGasPrice=field_mapjson__"effectiveGasPrice"String_.of_jsoninletcumulativeGasUsed=field_mapjson__"cumulativeGasUsed"String_.of_jsoninletgasUsed=field_mapjson__"gasUsed"String_.of_jsoninletcontractAddress=field_mapjson__"contractAddress"ChainAddress.of_jsoninletfrom=field_mapjson__"from"ChainAddress.of_jsoninletto_=field_mapjson__"to"ChainAddress.of_jsoninletnumberOfTransactions=field_mapjson__"numberOfTransactions"Long.of_jsoninlettransactionIndex=field_mapjson__"transactionIndex"Long.of_jsoninlettransactionTimestamp=field_mapjson__"transactionTimestamp"Timestamp.of_jsoninletblockNumber=field_mapjson__"blockNumber"String_.of_jsoninlettransactionHash=field_mapjson__"transactionHash"QueryTransactionHash.of_jsoninletblockHash=field_mapjson__"blockHash"BlockHash.of_jsoninletnetwork=field_mapjson__"network"QueryNetwork.of_jsoninmake?executionStatus?confirmationStatus?transactionId?transactionFee?signatureS?signatureR?signatureV?effectiveGasPrice?cumulativeGasUsed?gasUsed?contractAddress?from?to_?numberOfTransactions?transactionIndex?transactionTimestamp?blockNumber?transactionHash?blockHash?network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"There are two possible types of transactions used for this data type: A Bitcoin transaction is a movement of BTC from one address to another. An Ethereum transaction refers to an action initiated by an externally owned account, which is an account managed by a human, not a contract. For example, if Bob sends Alice 1 ETH, Bob's account must be debited and Alice's must be credited. This state-changing action occurs within a transaction."]moduleContractMetadata=structtypenonrect={name:String_.toption[@ocaml.doc"The name of the token contract."];symbol:String_.toption[@ocaml.doc"The symbol of the token contract."];decimals:Integer.toption[@ocaml.doc"The decimals used by the token contract."]}letmake?name=fun?symbol->fun?decimals->fun()->{name;symbol;decimals}letto_valuex=structure_to_value[("name",(Option.mapx.name~f:String_.to_value));("symbol",(Option.mapx.symbol~f:String_.to_value));("decimals",(Option.mapx.decimals~f:Integer.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letdecimals=(Option.map~f:Integer.of_xml)(Xml.childxml_arg0"decimals")inletsymbol=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"symbol")inletname=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"name")inmake?decimals?symbol?name()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letdecimals=field_mapjson__"decimals"Integer.of_jsoninletsymbol=field_mapjson__"symbol"String_.of_jsoninletname=field_mapjson__"name"String_.of_jsoninmake?decimals?symbol?name()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"The metadata of the contract."]moduleBatchGetTokenBalanceErrors=structtypenonrect=BatchGetTokenBalanceErrorItem.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:10)>>=(fun()->check_list_mini~min:0));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:BatchGetTokenBalanceErrorItem.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:BatchGetTokenBalanceErrorItem.of_xml)letof_jsonj=list_of_json~kind:"BatchGetTokenBalanceErrors"~of_json:BatchGetTokenBalanceErrorItem.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleBatchGetTokenBalanceOutputList=structtypenonrect=BatchGetTokenBalanceOutputItem.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:10)>>=(fun()->check_list_mini~min:0));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:BatchGetTokenBalanceOutputItem.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:BatchGetTokenBalanceOutputItem.of_xml)letof_jsonj=list_of_json~kind:"BatchGetTokenBalanceOutputList"~of_json:BatchGetTokenBalanceOutputItem.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleGetTokenBalanceInputList=structtypenonrect=BatchGetTokenBalanceInputItem.tlistletmakei=letopenResultinok_or_failwith((check_list_maxi~max:10)>>=(fun()->check_list_mini~min:1));iletof_string_=failwithf"of_string is not implemented for List_shape objects"()[@@warning"-32"]letto_valuexs=(xs|>(List.map~f:BatchGetTokenBalanceInputItem.to_value))|>(funx->`Listx)letto_queryv=to_queryto_valuevletto_header_=failwithf"to_header is not implemented for List_shape objects"()letof_xmlx=make(List.map((Xml.all_childrenx)|>(List.filter~f:(function|`Datas->(matchStdlib.String.trimswith|""->false|_->true)|_->true)))~f:BatchGetTokenBalanceInputItem.of_xml)letof_jsonj=list_of_json~kind:"GetTokenBalanceInputList"~of_json:BatchGetTokenBalanceInputItem.of_jsonjletto_jsonv=composed_to_jsonto_valuevendmoduleListTransactionsOutput=structtypenonrect={transactions:TransactionOutputList.toption[@ocaml.doc"The array of transactions returned by the request."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?transactions=fun?nextToken->fun()->{transactions;nextToken}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("transactions",(Option.mapx.transactions~f:TransactionOutputList.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inlettransactions=(Option.map~f:TransactionOutputList.of_xml)(Xml.childxml_arg0"transactions")inmake?nextToken?transactions()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letnextToken=field_mapjson__"nextToken"NextToken.of_jsoninlettransactions=field_mapjson__"transactions"TransactionOutputList.of_jsoninmake?nextToken?transactions()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for a transaction."]moduleListTransactionsInput=structtypenonrect={address:ChainAddress.t[@ocaml.doc"The address (either a contract or wallet), whose transactions are being requested."];network:QueryNetwork.t[@ocaml.doc"The blockchain network where the transactions occurred."];fromBlockchainInstant:BlockchainInstant.toption;toBlockchainInstant:BlockchainInstant.toption;sort:ListTransactionsSort.toption[@ocaml.doc"The order by which the results will be sorted."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."];maxResults:ListTransactionsInputMaxResultsInteger.toption[@ocaml.doc"The maximum number of transactions to list. Default: 100 Even if additional results can be retrieved, the request can return less results than maxResults or an empty array of results. To retrieve the next set of results, make another request with the returned nextToken value. The value of nextToken is null when there are no more results to return"];confirmationStatusFilter:ConfirmationStatusFilter.toption[@ocaml.doc"This filter is used to include transactions in the response that haven't reached finality . Transactions that have reached finality are always part of the response."]}letcontext_="ListTransactionsInput"letmake?fromBlockchainInstant=fun?toBlockchainInstant->fun?sort->fun?nextToken->fun?maxResults->fun?confirmationStatusFilter->fun~address->fun~network->fun()->{fromBlockchainInstant;toBlockchainInstant;sort;nextToken;maxResults;confirmationStatusFilter;address;network}letto_valuex=structure_to_value[("address",(Some(ChainAddress.to_valuex.address)));("network",(Some(QueryNetwork.to_valuex.network)));("fromBlockchainInstant",(Option.mapx.fromBlockchainInstant~f:BlockchainInstant.to_value));("toBlockchainInstant",(Option.mapx.toBlockchainInstant~f:BlockchainInstant.to_value));("sort",(Option.mapx.sort~f:ListTransactionsSort.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value));("maxResults",(Option.mapx.maxResults~f:ListTransactionsInputMaxResultsInteger.to_value));("confirmationStatusFilter",(Option.mapx.confirmationStatusFilter~f:ConfirmationStatusFilter.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letconfirmationStatusFilter=(Option.map~f:ConfirmationStatusFilter.of_xml)(Xml.childxml_arg0"confirmationStatusFilter")inletmaxResults=(Option.map~f:ListTransactionsInputMaxResultsInteger.of_xml)(Xml.childxml_arg0"maxResults")inletnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletsort=(Option.map~f:ListTransactionsSort.of_xml)(Xml.childxml_arg0"sort")inlettoBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"toBlockchainInstant")inletfromBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"fromBlockchainInstant")inletnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inletaddress=ChainAddress.of_xml(Xml.child_exn~context:context_xml_arg0"address")inmake?confirmationStatusFilter?maxResults?nextToken?sort?toBlockchainInstant?fromBlockchainInstant~network~address()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letconfirmationStatusFilter=field_mapjson__"confirmationStatusFilter"ConfirmationStatusFilter.of_jsoninletmaxResults=field_mapjson__"maxResults"ListTransactionsInputMaxResultsInteger.of_jsoninletnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletsort=field_mapjson__"sort"ListTransactionsSort.of_jsoninlettoBlockchainInstant=field_mapjson__"toBlockchainInstant"BlockchainInstant.of_jsoninletfromBlockchainInstant=field_mapjson__"fromBlockchainInstant"BlockchainInstant.of_jsoninletnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninletaddress=field_map_exnjson__"address"ChainAddress.of_jsoninmake?confirmationStatusFilter?maxResults?nextToken?sort?toBlockchainInstant?fromBlockchainInstant~network~address()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for a transaction."]moduleListTransactionEventsOutput=structtypenonrect={events:TransactionEventList.toption[@ocaml.doc"An array of TransactionEvent objects. Each object contains details about the transaction events."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?events=fun?nextToken->fun()->{events;nextToken}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("events",(Option.mapx.events~f:TransactionEventList.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletevents=(Option.map~f:TransactionEventList.of_xml)(Xml.childxml_arg0"events")inmake?nextToken?events()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletevents=field_mapjson__"events"TransactionEventList.of_jsoninmake?nextToken?events()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for a transaction This action will return transaction details for all transactions that are confirmed on the blockchain, even if they have not reached finality."]moduleListTransactionEventsInput=structtypenonrect={transactionHash:QueryTransactionHash.toption[@ocaml.doc"The hash of a transaction. It is generated when a transaction is created."];transactionId:QueryTransactionId.toption[@ocaml.doc"The identifier of a Bitcoin transaction. It is generated when a transaction is created. transactionId is only supported on the Bitcoin networks."];network:QueryNetwork.t[@ocaml.doc"The blockchain network where the transaction events occurred."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."];maxResults:ListTransactionEventsInputMaxResultsInteger.toption[@ocaml.doc"The maximum number of transaction events to list. Default: 100 Even if additional results can be retrieved, the request can return less results than maxResults or an empty array of results. To retrieve the next set of results, make another request with the returned nextToken value. The value of nextToken is null when there are no more results to return"]}letcontext_="ListTransactionEventsInput"letmake?transactionHash=fun?transactionId->fun?nextToken->fun?maxResults->fun~network->fun()->{transactionHash;transactionId;nextToken;maxResults;network}letto_valuex=structure_to_value[("transactionHash",(Option.mapx.transactionHash~f:QueryTransactionHash.to_value));("transactionId",(Option.mapx.transactionId~f:QueryTransactionId.to_value));("network",(Some(QueryNetwork.to_valuex.network)));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value));("maxResults",(Option.mapx.maxResults~f:ListTransactionEventsInputMaxResultsInteger.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmaxResults=(Option.map~f:ListTransactionEventsInputMaxResultsInteger.of_xml)(Xml.childxml_arg0"maxResults")inletnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inlettransactionId=(Option.map~f:QueryTransactionId.of_xml)(Xml.childxml_arg0"transactionId")inlettransactionHash=(Option.map~f:QueryTransactionHash.of_xml)(Xml.childxml_arg0"transactionHash")inmake?maxResults?nextToken~network?transactionId?transactionHash()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmaxResults=field_mapjson__"maxResults"ListTransactionEventsInputMaxResultsInteger.of_jsoninletnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninlettransactionId=field_mapjson__"transactionId"QueryTransactionId.of_jsoninlettransactionHash=field_mapjson__"transactionHash"QueryTransactionHash.of_jsoninmake?maxResults?nextToken~network?transactionId?transactionHash()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for a transaction This action will return transaction details for all transactions that are confirmed on the blockchain, even if they have not reached finality."]moduleListTokenBalancesOutput=structtypenonrect={tokenBalances:TokenBalanceList.toption[@ocaml.doc"An array of TokenBalance objects. Each object contains details about the token balance."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?tokenBalances=fun?nextToken->fun()->{tokenBalances;nextToken}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("tokenBalances",(Option.mapx.tokenBalances~f:TokenBalanceList.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inlettokenBalances=(Option.map~f:TokenBalanceList.of_xml)(Xml.childxml_arg0"tokenBalances")inmake?nextToken?tokenBalances()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letnextToken=field_mapjson__"nextToken"NextToken.of_jsoninlettokenBalances=field_mapjson__"tokenBalances"TokenBalanceList.of_jsoninmake?nextToken?tokenBalances()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"This action returns the following for a given blockchain network: Lists all token balances owned by an address (either a contract address or a wallet address). Lists all token balances for all tokens created by a contract. Lists all token balances for a given token. You must always specify the network property of the tokenFilter when using this operation."]moduleListTokenBalancesInput=structtypenonrect={ownerFilter:OwnerFilter.toption[@ocaml.doc"The contract or wallet address on the blockchain network by which to filter the request. You must specify the address property of the ownerFilter when listing balances of tokens owned by the address."];tokenFilter:TokenFilter.t[@ocaml.doc"The contract address or a token identifier on the blockchain network by which to filter the request. You must specify the contractAddress property of this container when listing tokens minted by a contract. You must always specify the network property of this container when using this operation."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."];maxResults:ListTokenBalancesInputMaxResultsInteger.toption[@ocaml.doc"The maximum number of token balances to return. Default: 100 Even if additional results can be retrieved, the request can return less results than maxResults or an empty array of results. To retrieve the next set of results, make another request with the returned nextToken value. The value of nextToken is null when there are no more results to return"]}letcontext_="ListTokenBalancesInput"letmake?ownerFilter=fun?nextToken->fun?maxResults->fun~tokenFilter->fun()->{ownerFilter;nextToken;maxResults;tokenFilter}letto_valuex=structure_to_value[("ownerFilter",(Option.mapx.ownerFilter~f:OwnerFilter.to_value));("tokenFilter",(Some(TokenFilter.to_valuex.tokenFilter)));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value));("maxResults",(Option.mapx.maxResults~f:ListTokenBalancesInputMaxResultsInteger.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmaxResults=(Option.map~f:ListTokenBalancesInputMaxResultsInteger.of_xml)(Xml.childxml_arg0"maxResults")inletnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inlettokenFilter=TokenFilter.of_xml(Xml.child_exn~context:context_xml_arg0"tokenFilter")inletownerFilter=(Option.map~f:OwnerFilter.of_xml)(Xml.childxml_arg0"ownerFilter")inmake?maxResults?nextToken~tokenFilter?ownerFilter()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmaxResults=field_mapjson__"maxResults"ListTokenBalancesInputMaxResultsInteger.of_jsoninletnextToken=field_mapjson__"nextToken"NextToken.of_jsoninlettokenFilter=field_map_exnjson__"tokenFilter"TokenFilter.of_jsoninletownerFilter=field_mapjson__"ownerFilter"OwnerFilter.of_jsoninmake?maxResults?nextToken~tokenFilter?ownerFilter()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"This action returns the following for a given blockchain network: Lists all token balances owned by an address (either a contract address or a wallet address). Lists all token balances for all tokens created by a contract. Lists all token balances for a given token. You must always specify the network property of the tokenFilter when using this operation."]moduleListFilteredTransactionEventsOutput=structtypenonrect={events:TransactionEventList.toption[@ocaml.doc"The transaction events returned by the request."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?events=fun?nextToken->fun()->{events;nextToken}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("events",(Option.mapx.events~f:TransactionEventList.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletevents=(Option.map~f:TransactionEventList.of_xml)(Xml.childxml_arg0"events")inmake?nextToken?events()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletevents=field_mapjson__"events"TransactionEventList.of_jsoninmake?nextToken?events()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for an address on the blockchain. This operation is only supported on the Bitcoin networks."]moduleListFilteredTransactionEventsInput=structtypenonrect={network:String_.t[@ocaml.doc"The blockchain network where the transaction occurred. Valid Values: BITCOIN_MAINNET | BITCOIN_TESTNET"];addressIdentifierFilter:AddressIdentifierFilter.t[@ocaml.doc"This is the unique public address on the blockchain for which the transaction events are being requested."];timeFilter:TimeFilter.toption[@ocaml.doc"This container specifies the time frame for the transaction events returned in the response."];voutFilter:VoutFilter.toption[@ocaml.doc"This container specifies filtering attributes related to BITCOIN_VOUT event types"];confirmationStatusFilter:ConfirmationStatusFilter.toption;sort:ListFilteredTransactionEventsSort.toption[@ocaml.doc"The order by which the results will be sorted."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."];maxResults:ListFilteredTransactionEventsInputMaxResultsInteger.toption[@ocaml.doc"The maximum number of transaction events to list. Default: 100 Even if additional results can be retrieved, the request can return less results than maxResults or an empty array of results. To retrieve the next set of results, make another request with the returned nextToken value. The value of nextToken is null when there are no more results to return"]}letcontext_="ListFilteredTransactionEventsInput"letmake?timeFilter=fun?voutFilter->fun?confirmationStatusFilter->fun?sort->fun?nextToken->fun?maxResults->fun~network->fun~addressIdentifierFilter->fun()->{timeFilter;voutFilter;confirmationStatusFilter;sort;nextToken;maxResults;network;addressIdentifierFilter}letto_valuex=structure_to_value[("network",(Some(String_.to_valuex.network)));("addressIdentifierFilter",(Some(AddressIdentifierFilter.to_valuex.addressIdentifierFilter)));("timeFilter",(Option.mapx.timeFilter~f:TimeFilter.to_value));("voutFilter",(Option.mapx.voutFilter~f:VoutFilter.to_value));("confirmationStatusFilter",(Option.mapx.confirmationStatusFilter~f:ConfirmationStatusFilter.to_value));("sort",(Option.mapx.sort~f:ListFilteredTransactionEventsSort.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value));("maxResults",(Option.mapx.maxResults~f:ListFilteredTransactionEventsInputMaxResultsInteger.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmaxResults=(Option.map~f:ListFilteredTransactionEventsInputMaxResultsInteger.of_xml)(Xml.childxml_arg0"maxResults")inletnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletsort=(Option.map~f:ListFilteredTransactionEventsSort.of_xml)(Xml.childxml_arg0"sort")inletconfirmationStatusFilter=(Option.map~f:ConfirmationStatusFilter.of_xml)(Xml.childxml_arg0"confirmationStatusFilter")inletvoutFilter=(Option.map~f:VoutFilter.of_xml)(Xml.childxml_arg0"voutFilter")inlettimeFilter=(Option.map~f:TimeFilter.of_xml)(Xml.childxml_arg0"timeFilter")inletaddressIdentifierFilter=AddressIdentifierFilter.of_xml(Xml.child_exn~context:context_xml_arg0"addressIdentifierFilter")inletnetwork=String_.of_xml(Xml.child_exn~context:context_xml_arg0"network")inmake?maxResults?nextToken?sort?confirmationStatusFilter?voutFilter?timeFilter~addressIdentifierFilter~network()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmaxResults=field_mapjson__"maxResults"ListFilteredTransactionEventsInputMaxResultsInteger.of_jsoninletnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletsort=field_mapjson__"sort"ListFilteredTransactionEventsSort.of_jsoninletconfirmationStatusFilter=field_mapjson__"confirmationStatusFilter"ConfirmationStatusFilter.of_jsoninletvoutFilter=field_mapjson__"voutFilter"VoutFilter.of_jsoninlettimeFilter=field_mapjson__"timeFilter"TimeFilter.of_jsoninletaddressIdentifierFilter=field_map_exnjson__"addressIdentifierFilter"AddressIdentifierFilter.of_jsoninletnetwork=field_map_exnjson__"network"String_.of_jsoninmake?maxResults?nextToken?sort?confirmationStatusFilter?voutFilter?timeFilter~addressIdentifierFilter~network()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the transaction events for an address on the blockchain. This operation is only supported on the Bitcoin networks."]moduleListAssetContractsOutput=structtypenonrect={contracts:AssetContractList.toption[@ocaml.doc"An array of contract objects that contain the properties for each contract."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?contracts=fun?nextToken->fun()->{contracts;nextToken}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("contracts",(Option.mapx.contracts~f:AssetContractList.to_value));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletcontracts=(Option.map~f:AssetContractList.of_xml)(Xml.childxml_arg0"contracts")inmake?nextToken?contracts()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletcontracts=field_mapjson__"contracts"AssetContractList.of_jsoninmake?nextToken?contracts()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the contracts for a given contract type deployed by an address (either a contract address or a wallet address). The Bitcoin blockchain networks do not support this operation."]moduleListAssetContractsInput=structtypenonrect={contractFilter:ContractFilter.t[@ocaml.doc"Contains the filter parameter for the request."];nextToken:NextToken.toption[@ocaml.doc"The pagination token that indicates the next set of results to retrieve."];maxResults:ListAssetContractsInputMaxResultsInteger.toption[@ocaml.doc"The maximum number of contracts to list. Default: 100 Even if additional results can be retrieved, the request can return less results than maxResults or an empty array of results. To retrieve the next set of results, make another request with the returned nextToken value. The value of nextToken is null when there are no more results to return"]}letcontext_="ListAssetContractsInput"letmake?nextToken=fun?maxResults->fun~contractFilter->fun()->{nextToken;maxResults;contractFilter}letto_valuex=structure_to_value[("contractFilter",(Some(ContractFilter.to_valuex.contractFilter)));("nextToken",(Option.mapx.nextToken~f:NextToken.to_value));("maxResults",(Option.mapx.maxResults~f:ListAssetContractsInputMaxResultsInteger.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmaxResults=(Option.map~f:ListAssetContractsInputMaxResultsInteger.of_xml)(Xml.childxml_arg0"maxResults")inletnextToken=(Option.map~f:NextToken.of_xml)(Xml.childxml_arg0"nextToken")inletcontractFilter=ContractFilter.of_xml(Xml.child_exn~context:context_xml_arg0"contractFilter")inmake?maxResults?nextToken~contractFilter()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmaxResults=field_mapjson__"maxResults"ListAssetContractsInputMaxResultsInteger.of_jsoninletnextToken=field_mapjson__"nextToken"NextToken.of_jsoninletcontractFilter=field_map_exnjson__"contractFilter"ContractFilter.of_jsoninmake?maxResults?nextToken~contractFilter()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Lists all the contracts for a given contract type deployed by an address (either a contract address or a wallet address). The Bitcoin blockchain networks do not support this operation."]moduleGetTransactionOutput=structtypenonrect={transaction:Transaction.toption[@ocaml.doc"Contains the details of the transaction."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ResourceNotFoundExceptionofResourceNotFoundException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?transaction=fun()->{transaction}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ResourceNotFoundExceptione->`Assoc[("error",(`String"ResourceNotFoundException"));("details",(ResourceNotFoundException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("transaction",(Option.mapx.transaction~f:Transaction.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=lettransaction=(Option.map~f:Transaction.of_xml)(Xml.childxml_arg0"transaction")inmake?transaction()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=lettransaction=field_mapjson__"transaction"Transaction.of_jsoninmake?transaction()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the details of a transaction. This action will return transaction details for all transactions that are confirmed on the blockchain, even if they have not reached finality."]moduleGetTransactionInput=structtypenonrect={transactionHash:QueryTransactionHash.toption[@ocaml.doc"The hash of a transaction. It is generated when a transaction is created."];transactionId:QueryTransactionId.toption[@ocaml.doc"The identifier of a Bitcoin transaction. It is generated when a transaction is created. transactionId is only supported on the Bitcoin networks."];network:QueryNetwork.t[@ocaml.doc"The blockchain network where the transaction occurred."]}letcontext_="GetTransactionInput"letmake?transactionHash=fun?transactionId->fun~network->fun()->{transactionHash;transactionId;network}letto_valuex=structure_to_value[("transactionHash",(Option.mapx.transactionHash~f:QueryTransactionHash.to_value));("transactionId",(Option.mapx.transactionId~f:QueryTransactionId.to_value));("network",(Some(QueryNetwork.to_valuex.network)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letnetwork=QueryNetwork.of_xml(Xml.child_exn~context:context_xml_arg0"network")inlettransactionId=(Option.map~f:QueryTransactionId.of_xml)(Xml.childxml_arg0"transactionId")inlettransactionHash=(Option.map~f:QueryTransactionHash.of_xml)(Xml.childxml_arg0"transactionHash")inmake~network?transactionId?transactionHash()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letnetwork=field_map_exnjson__"network"QueryNetwork.of_jsoninlettransactionId=field_mapjson__"transactionId"QueryTransactionId.of_jsoninlettransactionHash=field_mapjson__"transactionHash"QueryTransactionHash.of_jsoninmake~network?transactionId?transactionHash()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the details of a transaction. This action will return transaction details for all transactions that are confirmed on the blockchain, even if they have not reached finality."]moduleGetTokenBalanceOutput=structtypenonrect={ownerIdentifier:OwnerIdentifier.toption;tokenIdentifier:TokenIdentifier.toption;balance:String_.toption[@ocaml.doc"The container for the token balance."];atBlockchainInstant:BlockchainInstant.toption;lastUpdatedTime:BlockchainInstant.toption}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ResourceNotFoundExceptionofResourceNotFoundException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?ownerIdentifier=fun?tokenIdentifier->fun?balance->fun?atBlockchainInstant->fun?lastUpdatedTime->fun()->{ownerIdentifier;tokenIdentifier;balance;atBlockchainInstant;lastUpdatedTime}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ResourceNotFoundExceptione->`Assoc[("error",(`String"ResourceNotFoundException"));("details",(ResourceNotFoundException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("ownerIdentifier",(Option.mapx.ownerIdentifier~f:OwnerIdentifier.to_value));("tokenIdentifier",(Option.mapx.tokenIdentifier~f:TokenIdentifier.to_value));("balance",(Option.mapx.balance~f:String_.to_value));("atBlockchainInstant",(Option.mapx.atBlockchainInstant~f:BlockchainInstant.to_value));("lastUpdatedTime",(Option.mapx.lastUpdatedTime~f:BlockchainInstant.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letlastUpdatedTime=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"lastUpdatedTime")inletatBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"atBlockchainInstant")inletbalance=(Option.map~f:String_.of_xml)(Xml.childxml_arg0"balance")inlettokenIdentifier=(Option.map~f:TokenIdentifier.of_xml)(Xml.childxml_arg0"tokenIdentifier")inletownerIdentifier=(Option.map~f:OwnerIdentifier.of_xml)(Xml.childxml_arg0"ownerIdentifier")inmake?lastUpdatedTime?atBlockchainInstant?balance?tokenIdentifier?ownerIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letlastUpdatedTime=field_mapjson__"lastUpdatedTime"BlockchainInstant.of_jsoninletatBlockchainInstant=field_mapjson__"atBlockchainInstant"BlockchainInstant.of_jsoninletbalance=field_mapjson__"balance"String_.of_jsoninlettokenIdentifier=field_mapjson__"tokenIdentifier"TokenIdentifier.of_jsoninletownerIdentifier=field_mapjson__"ownerIdentifier"OwnerIdentifier.of_jsoninmake?lastUpdatedTime?atBlockchainInstant?balance?tokenIdentifier?ownerIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported."]moduleGetTokenBalanceInput=structtypenonrect={tokenIdentifier:TokenIdentifier.t[@ocaml.doc"The container for the identifier for the token, including the unique token ID and its blockchain network."];ownerIdentifier:OwnerIdentifier.t[@ocaml.doc"The container for the identifier for the owner."];atBlockchainInstant:BlockchainInstant.toption[@ocaml.doc"The time for when the TokenBalance is requested or the current time if a time is not provided in the request. This time will only be recorded up to the second."]}letcontext_="GetTokenBalanceInput"letmake?atBlockchainInstant=fun~tokenIdentifier->fun~ownerIdentifier->fun()->{atBlockchainInstant;tokenIdentifier;ownerIdentifier}letto_valuex=structure_to_value[("tokenIdentifier",(Some(TokenIdentifier.to_valuex.tokenIdentifier)));("ownerIdentifier",(Some(OwnerIdentifier.to_valuex.ownerIdentifier)));("atBlockchainInstant",(Option.mapx.atBlockchainInstant~f:BlockchainInstant.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letatBlockchainInstant=(Option.map~f:BlockchainInstant.of_xml)(Xml.childxml_arg0"atBlockchainInstant")inletownerIdentifier=OwnerIdentifier.of_xml(Xml.child_exn~context:context_xml_arg0"ownerIdentifier")inlettokenIdentifier=TokenIdentifier.of_xml(Xml.child_exn~context:context_xml_arg0"tokenIdentifier")inmake?atBlockchainInstant~ownerIdentifier~tokenIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letatBlockchainInstant=field_mapjson__"atBlockchainInstant"BlockchainInstant.of_jsoninletownerIdentifier=field_map_exnjson__"ownerIdentifier"OwnerIdentifier.of_jsoninlettokenIdentifier=field_map_exnjson__"tokenIdentifier"TokenIdentifier.of_jsoninmake?atBlockchainInstant~ownerIdentifier~tokenIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the balance of a specific token, including native tokens, for a given address (wallet or contract) on the blockchain. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported."]moduleGetAssetContractOutput=structtypenonrect={contractIdentifier:ContractIdentifier.toption[@ocaml.doc"Contains the blockchain address and network information about the contract."];tokenStandard:QueryTokenStandard.toption[@ocaml.doc"The token standard of the contract requested."];deployerAddress:ChainAddress.toption[@ocaml.doc"The address of the deployer of contract."];metadata:ContractMetadata.toption}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ResourceNotFoundExceptionofResourceNotFoundException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?contractIdentifier=fun?tokenStandard->fun?deployerAddress->fun?metadata->fun()->{contractIdentifier;tokenStandard;deployerAddress;metadata}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ResourceNotFoundExceptione->`Assoc[("error",(`String"ResourceNotFoundException"));("details",(ResourceNotFoundException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("contractIdentifier",(Option.mapx.contractIdentifier~f:ContractIdentifier.to_value));("tokenStandard",(Option.mapx.tokenStandard~f:QueryTokenStandard.to_value));("deployerAddress",(Option.mapx.deployerAddress~f:ChainAddress.to_value));("metadata",(Option.mapx.metadata~f:ContractMetadata.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letmetadata=(Option.map~f:ContractMetadata.of_xml)(Xml.childxml_arg0"metadata")inletdeployerAddress=(Option.map~f:ChainAddress.of_xml)(Xml.childxml_arg0"deployerAddress")inlettokenStandard=(Option.map~f:QueryTokenStandard.of_xml)(Xml.childxml_arg0"tokenStandard")inletcontractIdentifier=(Option.map~f:ContractIdentifier.of_xml)(Xml.childxml_arg0"contractIdentifier")inmake?metadata?deployerAddress?tokenStandard?contractIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letmetadata=field_mapjson__"metadata"ContractMetadata.of_jsoninletdeployerAddress=field_mapjson__"deployerAddress"ChainAddress.of_jsoninlettokenStandard=field_mapjson__"tokenStandard"QueryTokenStandard.of_jsoninletcontractIdentifier=field_mapjson__"contractIdentifier"ContractIdentifier.of_jsoninmake?metadata?deployerAddress?tokenStandard?contractIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the information about a specific contract deployed on the blockchain. The Bitcoin blockchain networks do not support this operation. Metadata is currently only available for some ERC-20 contracts. Metadata will be available for additional contracts in the future."]moduleGetAssetContractInput=structtypenonrect={contractIdentifier:ContractIdentifier.t[@ocaml.doc"Contains the blockchain address and network information about the contract."]}letcontext_="GetAssetContractInput"letmake~contractIdentifier=fun()->{contractIdentifier}letto_valuex=structure_to_value[("contractIdentifier",(Some(ContractIdentifier.to_valuex.contractIdentifier)))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letcontractIdentifier=ContractIdentifier.of_xml(Xml.child_exn~context:context_xml_arg0"contractIdentifier")inmake~contractIdentifier()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letcontractIdentifier=field_map_exnjson__"contractIdentifier"ContractIdentifier.of_jsoninmake~contractIdentifier()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the information about a specific contract deployed on the blockchain. The Bitcoin blockchain networks do not support this operation. Metadata is currently only available for some ERC-20 contracts. Metadata will be available for additional contracts in the future."]moduleBatchGetTokenBalanceOutput=structtypenonrect={tokenBalances:BatchGetTokenBalanceOutputList.toption[@ocaml.doc"An array of BatchGetTokenBalanceOutputItem objects returned by the response."];errors:BatchGetTokenBalanceErrors.toption[@ocaml.doc"An array of BatchGetTokenBalanceErrorItem objects returned from the request."]}typenonrecerror=[`AccessDeniedExceptionofAccessDeniedException.t|`InternalServerExceptionofInternalServerException.t|`ResourceNotFoundExceptionofResourceNotFoundException.t|`ServiceQuotaExceededExceptionofServiceQuotaExceededException.t|`ThrottlingExceptionofThrottlingException.t|`ValidationExceptionofValidationException.t|`Unknown_operation_errorof(string*stringoption)]letmake?tokenBalances=fun?errors->fun()->{tokenBalances;errors}leterror_of_jsonnamejson=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_jsonjson)|"InternalServerException"->`InternalServerException(InternalServerException.of_jsonjson)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_jsonjson)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_jsonjson)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_jsonjson)|"ValidationException"->`ValidationException(ValidationException.of_jsonjson)|name->`Unknown_operation_error(name,(Some(Yojson.Safe.to_stringjson)))leterror_of_xmlnamexml=matchnamewith|"AccessDeniedException"->`AccessDeniedException(AccessDeniedException.of_xmlxml)|"InternalServerException"->`InternalServerException(InternalServerException.of_xmlxml)|"ResourceNotFoundException"->`ResourceNotFoundException(ResourceNotFoundException.of_xmlxml)|"ServiceQuotaExceededException"->`ServiceQuotaExceededException(ServiceQuotaExceededException.of_xmlxml)|"ThrottlingException"->`ThrottlingException(ThrottlingException.of_xmlxml)|"ValidationException"->`ValidationException(ValidationException.of_xmlxml)|name->`Unknown_operation_error(name,(Some(Awso.Xml.to_stringxml)))leterror_to_json:error->Yojson.Safe.t=function|`AccessDeniedExceptione->`Assoc[("error",(`String"AccessDeniedException"));("details",(AccessDeniedException.to_jsone))]|`InternalServerExceptione->`Assoc[("error",(`String"InternalServerException"));("details",(InternalServerException.to_jsone))]|`ResourceNotFoundExceptione->`Assoc[("error",(`String"ResourceNotFoundException"));("details",(ResourceNotFoundException.to_jsone))]|`ServiceQuotaExceededExceptione->`Assoc[("error",(`String"ServiceQuotaExceededException"));("details",(ServiceQuotaExceededException.to_jsone))]|`ThrottlingExceptione->`Assoc[("error",(`String"ThrottlingException"));("details",(ThrottlingException.to_jsone))]|`ValidationExceptione->`Assoc[("error",(`String"ValidationException"));("details",(ValidationException.to_jsone))]|`Unknown_operation_error(code,msg)->`Assoc(("error",(`Stringcode))::((matchmsgwith|None->[]|Somem->[("message",(`Stringm))])))letto_valuex=structure_to_value[("tokenBalances",(Option.mapx.tokenBalances~f:BatchGetTokenBalanceOutputList.to_value));("errors",(Option.mapx.errors~f:BatchGetTokenBalanceErrors.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=leterrors=(Option.map~f:BatchGetTokenBalanceErrors.of_xml)(Xml.childxml_arg0"errors")inlettokenBalances=(Option.map~f:BatchGetTokenBalanceOutputList.of_xml)(Xml.childxml_arg0"tokenBalances")inmake?errors?tokenBalances()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=leterrors=field_mapjson__"errors"BatchGetTokenBalanceErrors.of_jsoninlettokenBalances=field_mapjson__"tokenBalances"BatchGetTokenBalanceOutputList.of_jsoninmake?errors?tokenBalances()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the token balance for a batch of tokens by using the BatchGetTokenBalance action for every token in the request. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported."]moduleBatchGetTokenBalanceInput=structtypenonrect={getTokenBalanceInputs:GetTokenBalanceInputList.toption[@ocaml.doc"An array of BatchGetTokenBalanceInputItem objects whose balance is being requested."]}letmake?getTokenBalanceInputs=fun()->{getTokenBalanceInputs}letto_valuex=structure_to_value[("getTokenBalanceInputs",(Option.mapx.getTokenBalanceInputs~f:GetTokenBalanceInputList.to_value))]letto_queryv=to_queryto_valuevletof_xmlxml_arg0=letgetTokenBalanceInputs=(Option.map~f:GetTokenBalanceInputList.of_xml)(Xml.childxml_arg0"getTokenBalanceInputs")inmake?getTokenBalanceInputs()letof_strings=of_xml(Awso.Xml.parse_responses)[@@warning"-32"]letof_jsonjson__=letgetTokenBalanceInputs=field_mapjson__"getTokenBalanceInputs"GetTokenBalanceInputList.of_jsoninmake?getTokenBalanceInputs()letto_jsonv=composed_to_jsonto_valuevend[@@ocaml.doc"Gets the token balance for a batch of tokens by using the BatchGetTokenBalance action for every token in the request. Only the native tokens BTC and ETH, and the ERC-20, ERC-721, and ERC 1155 token standards are supported."]