api.go 235 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390
  1. // THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
  2. // Package iot provides a client for AWS IoT.
  3. package iot
  4. import (
  5. "fmt"
  6. "time"
  7. "github.com/aws/aws-sdk-go/aws/awsutil"
  8. "github.com/aws/aws-sdk-go/aws/request"
  9. "github.com/aws/aws-sdk-go/private/protocol"
  10. "github.com/aws/aws-sdk-go/private/protocol/restjson"
  11. )
  12. const opAcceptCertificateTransfer = "AcceptCertificateTransfer"
  13. // AcceptCertificateTransferRequest generates a "aws/request.Request" representing the
  14. // client's request for the AcceptCertificateTransfer operation. The "output" return
  15. // value can be used to capture response data after the request's "Send" method
  16. // is called.
  17. //
  18. // Creating a request object using this method should be used when you want to inject
  19. // custom logic into the request's lifecycle using a custom handler, or if you want to
  20. // access properties on the request object before or after sending the request. If
  21. // you just want the service response, call the AcceptCertificateTransfer method directly
  22. // instead.
  23. //
  24. // Note: You must call the "Send" method on the returned request object in order
  25. // to execute the request.
  26. //
  27. // // Example sending a request using the AcceptCertificateTransferRequest method.
  28. // req, resp := client.AcceptCertificateTransferRequest(params)
  29. //
  30. // err := req.Send()
  31. // if err == nil { // resp is now filled
  32. // fmt.Println(resp)
  33. // }
  34. //
  35. func (c *IoT) AcceptCertificateTransferRequest(input *AcceptCertificateTransferInput) (req *request.Request, output *AcceptCertificateTransferOutput) {
  36. op := &request.Operation{
  37. Name: opAcceptCertificateTransfer,
  38. HTTPMethod: "PATCH",
  39. HTTPPath: "/accept-certificate-transfer/{certificateId}",
  40. }
  41. if input == nil {
  42. input = &AcceptCertificateTransferInput{}
  43. }
  44. req = c.newRequest(op, input, output)
  45. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  46. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  47. output = &AcceptCertificateTransferOutput{}
  48. req.Data = output
  49. return
  50. }
  51. // Accepts a pending certificate transfer. The default state of the certificate
  52. // is INACTIVE.
  53. //
  54. // To check for pending certificate transfers, call ListCertificates to enumerate
  55. // your certificates.
  56. func (c *IoT) AcceptCertificateTransfer(input *AcceptCertificateTransferInput) (*AcceptCertificateTransferOutput, error) {
  57. req, out := c.AcceptCertificateTransferRequest(input)
  58. err := req.Send()
  59. return out, err
  60. }
  61. const opAttachPrincipalPolicy = "AttachPrincipalPolicy"
  62. // AttachPrincipalPolicyRequest generates a "aws/request.Request" representing the
  63. // client's request for the AttachPrincipalPolicy operation. The "output" return
  64. // value can be used to capture response data after the request's "Send" method
  65. // is called.
  66. //
  67. // Creating a request object using this method should be used when you want to inject
  68. // custom logic into the request's lifecycle using a custom handler, or if you want to
  69. // access properties on the request object before or after sending the request. If
  70. // you just want the service response, call the AttachPrincipalPolicy method directly
  71. // instead.
  72. //
  73. // Note: You must call the "Send" method on the returned request object in order
  74. // to execute the request.
  75. //
  76. // // Example sending a request using the AttachPrincipalPolicyRequest method.
  77. // req, resp := client.AttachPrincipalPolicyRequest(params)
  78. //
  79. // err := req.Send()
  80. // if err == nil { // resp is now filled
  81. // fmt.Println(resp)
  82. // }
  83. //
  84. func (c *IoT) AttachPrincipalPolicyRequest(input *AttachPrincipalPolicyInput) (req *request.Request, output *AttachPrincipalPolicyOutput) {
  85. op := &request.Operation{
  86. Name: opAttachPrincipalPolicy,
  87. HTTPMethod: "PUT",
  88. HTTPPath: "/principal-policies/{policyName}",
  89. }
  90. if input == nil {
  91. input = &AttachPrincipalPolicyInput{}
  92. }
  93. req = c.newRequest(op, input, output)
  94. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  95. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  96. output = &AttachPrincipalPolicyOutput{}
  97. req.Data = output
  98. return
  99. }
  100. // Attaches the specified policy to the specified principal (certificate or
  101. // other credential).
  102. func (c *IoT) AttachPrincipalPolicy(input *AttachPrincipalPolicyInput) (*AttachPrincipalPolicyOutput, error) {
  103. req, out := c.AttachPrincipalPolicyRequest(input)
  104. err := req.Send()
  105. return out, err
  106. }
  107. const opAttachThingPrincipal = "AttachThingPrincipal"
  108. // AttachThingPrincipalRequest generates a "aws/request.Request" representing the
  109. // client's request for the AttachThingPrincipal operation. The "output" return
  110. // value can be used to capture response data after the request's "Send" method
  111. // is called.
  112. //
  113. // Creating a request object using this method should be used when you want to inject
  114. // custom logic into the request's lifecycle using a custom handler, or if you want to
  115. // access properties on the request object before or after sending the request. If
  116. // you just want the service response, call the AttachThingPrincipal method directly
  117. // instead.
  118. //
  119. // Note: You must call the "Send" method on the returned request object in order
  120. // to execute the request.
  121. //
  122. // // Example sending a request using the AttachThingPrincipalRequest method.
  123. // req, resp := client.AttachThingPrincipalRequest(params)
  124. //
  125. // err := req.Send()
  126. // if err == nil { // resp is now filled
  127. // fmt.Println(resp)
  128. // }
  129. //
  130. func (c *IoT) AttachThingPrincipalRequest(input *AttachThingPrincipalInput) (req *request.Request, output *AttachThingPrincipalOutput) {
  131. op := &request.Operation{
  132. Name: opAttachThingPrincipal,
  133. HTTPMethod: "PUT",
  134. HTTPPath: "/things/{thingName}/principals",
  135. }
  136. if input == nil {
  137. input = &AttachThingPrincipalInput{}
  138. }
  139. req = c.newRequest(op, input, output)
  140. output = &AttachThingPrincipalOutput{}
  141. req.Data = output
  142. return
  143. }
  144. // Attaches the specified principal to the specified thing.
  145. func (c *IoT) AttachThingPrincipal(input *AttachThingPrincipalInput) (*AttachThingPrincipalOutput, error) {
  146. req, out := c.AttachThingPrincipalRequest(input)
  147. err := req.Send()
  148. return out, err
  149. }
  150. const opCancelCertificateTransfer = "CancelCertificateTransfer"
  151. // CancelCertificateTransferRequest generates a "aws/request.Request" representing the
  152. // client's request for the CancelCertificateTransfer operation. The "output" return
  153. // value can be used to capture response data after the request's "Send" method
  154. // is called.
  155. //
  156. // Creating a request object using this method should be used when you want to inject
  157. // custom logic into the request's lifecycle using a custom handler, or if you want to
  158. // access properties on the request object before or after sending the request. If
  159. // you just want the service response, call the CancelCertificateTransfer method directly
  160. // instead.
  161. //
  162. // Note: You must call the "Send" method on the returned request object in order
  163. // to execute the request.
  164. //
  165. // // Example sending a request using the CancelCertificateTransferRequest method.
  166. // req, resp := client.CancelCertificateTransferRequest(params)
  167. //
  168. // err := req.Send()
  169. // if err == nil { // resp is now filled
  170. // fmt.Println(resp)
  171. // }
  172. //
  173. func (c *IoT) CancelCertificateTransferRequest(input *CancelCertificateTransferInput) (req *request.Request, output *CancelCertificateTransferOutput) {
  174. op := &request.Operation{
  175. Name: opCancelCertificateTransfer,
  176. HTTPMethod: "PATCH",
  177. HTTPPath: "/cancel-certificate-transfer/{certificateId}",
  178. }
  179. if input == nil {
  180. input = &CancelCertificateTransferInput{}
  181. }
  182. req = c.newRequest(op, input, output)
  183. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  184. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  185. output = &CancelCertificateTransferOutput{}
  186. req.Data = output
  187. return
  188. }
  189. // Cancels a pending transfer for the specified certificate.
  190. //
  191. // Note Only the transfer source account can use this operation to cancel a
  192. // transfer. (Transfer destinations can use RejectCertificateTransfer instead.)
  193. // After transfer, AWS IoT returns the certificate to the source account in
  194. // the INACTIVE state. After the destination account has accepted the transfer,
  195. // the transfer cannot be cancelled.
  196. //
  197. // After a certificate transfer is cancelled, the status of the certificate
  198. // changes from PENDING_TRANSFER to INACTIVE.
  199. func (c *IoT) CancelCertificateTransfer(input *CancelCertificateTransferInput) (*CancelCertificateTransferOutput, error) {
  200. req, out := c.CancelCertificateTransferRequest(input)
  201. err := req.Send()
  202. return out, err
  203. }
  204. const opCreateCertificateFromCsr = "CreateCertificateFromCsr"
  205. // CreateCertificateFromCsrRequest generates a "aws/request.Request" representing the
  206. // client's request for the CreateCertificateFromCsr operation. The "output" return
  207. // value can be used to capture response data after the request's "Send" method
  208. // is called.
  209. //
  210. // Creating a request object using this method should be used when you want to inject
  211. // custom logic into the request's lifecycle using a custom handler, or if you want to
  212. // access properties on the request object before or after sending the request. If
  213. // you just want the service response, call the CreateCertificateFromCsr method directly
  214. // instead.
  215. //
  216. // Note: You must call the "Send" method on the returned request object in order
  217. // to execute the request.
  218. //
  219. // // Example sending a request using the CreateCertificateFromCsrRequest method.
  220. // req, resp := client.CreateCertificateFromCsrRequest(params)
  221. //
  222. // err := req.Send()
  223. // if err == nil { // resp is now filled
  224. // fmt.Println(resp)
  225. // }
  226. //
  227. func (c *IoT) CreateCertificateFromCsrRequest(input *CreateCertificateFromCsrInput) (req *request.Request, output *CreateCertificateFromCsrOutput) {
  228. op := &request.Operation{
  229. Name: opCreateCertificateFromCsr,
  230. HTTPMethod: "POST",
  231. HTTPPath: "/certificates",
  232. }
  233. if input == nil {
  234. input = &CreateCertificateFromCsrInput{}
  235. }
  236. req = c.newRequest(op, input, output)
  237. output = &CreateCertificateFromCsrOutput{}
  238. req.Data = output
  239. return
  240. }
  241. // Creates an X.509 certificate using the specified certificate signing request.
  242. //
  243. // Note Reusing the same certificate signing request (CSR) results in a distinct
  244. // certificate.
  245. //
  246. // You can create multiple certificates in a batch by creating a directory,
  247. // copying multiple .csr files into that directory, and then specifying that
  248. // directory on the command line. The following commands show how to create
  249. // a batch of certificates given a batch of CSRs.
  250. //
  251. // Assuming a set of CSRs are located inside of the directory my-csr-directory:
  252. //
  253. // On Linux and OS X, the command is:
  254. //
  255. // $ ls my-csr-directory/ | xargs -I {} aws iot create-certificate-from-csr
  256. // --certificate-signing-request file://my-csr-directory/{}
  257. //
  258. // This command lists all of the CSRs in my-csr-directory and pipes each CSR
  259. // file name to the aws iot create-certificate-from-csr AWS CLI command to create
  260. // a certificate for the corresponding CSR.
  261. //
  262. // The aws iot create-certificate-from-csr part of the command can also be
  263. // run in parallel to speed up the certificate creation process:
  264. //
  265. // $ ls my-csr-directory/ | xargs -P 10 -I {} aws iot create-certificate-from-csr
  266. // --certificate-signing-request file://my-csr-directory/{}
  267. //
  268. // On Windows PowerShell, the command to create certificates for all CSRs
  269. // in my-csr-directory is:
  270. //
  271. // > ls -Name my-csr-directory | %{aws iot create-certificate-from-csr --certificate-signing-request
  272. // file://my-csr-directory/$_}
  273. //
  274. // On a Windows command prompt, the command to create certificates for all
  275. // CSRs in my-csr-directory is:
  276. //
  277. // > forfiles /p my-csr-directory /c "cmd /c aws iot create-certificate-from-csr
  278. // --certificate-signing-request file://@path"
  279. func (c *IoT) CreateCertificateFromCsr(input *CreateCertificateFromCsrInput) (*CreateCertificateFromCsrOutput, error) {
  280. req, out := c.CreateCertificateFromCsrRequest(input)
  281. err := req.Send()
  282. return out, err
  283. }
  284. const opCreateKeysAndCertificate = "CreateKeysAndCertificate"
  285. // CreateKeysAndCertificateRequest generates a "aws/request.Request" representing the
  286. // client's request for the CreateKeysAndCertificate operation. The "output" return
  287. // value can be used to capture response data after the request's "Send" method
  288. // is called.
  289. //
  290. // Creating a request object using this method should be used when you want to inject
  291. // custom logic into the request's lifecycle using a custom handler, or if you want to
  292. // access properties on the request object before or after sending the request. If
  293. // you just want the service response, call the CreateKeysAndCertificate method directly
  294. // instead.
  295. //
  296. // Note: You must call the "Send" method on the returned request object in order
  297. // to execute the request.
  298. //
  299. // // Example sending a request using the CreateKeysAndCertificateRequest method.
  300. // req, resp := client.CreateKeysAndCertificateRequest(params)
  301. //
  302. // err := req.Send()
  303. // if err == nil { // resp is now filled
  304. // fmt.Println(resp)
  305. // }
  306. //
  307. func (c *IoT) CreateKeysAndCertificateRequest(input *CreateKeysAndCertificateInput) (req *request.Request, output *CreateKeysAndCertificateOutput) {
  308. op := &request.Operation{
  309. Name: opCreateKeysAndCertificate,
  310. HTTPMethod: "POST",
  311. HTTPPath: "/keys-and-certificate",
  312. }
  313. if input == nil {
  314. input = &CreateKeysAndCertificateInput{}
  315. }
  316. req = c.newRequest(op, input, output)
  317. output = &CreateKeysAndCertificateOutput{}
  318. req.Data = output
  319. return
  320. }
  321. // Creates a 2048-bit RSA key pair and issues an X.509 certificate using the
  322. // issued public key.
  323. //
  324. // Note This is the only time AWS IoT issues the private key for this certificate,
  325. // so it is important to keep it in a secure location.
  326. func (c *IoT) CreateKeysAndCertificate(input *CreateKeysAndCertificateInput) (*CreateKeysAndCertificateOutput, error) {
  327. req, out := c.CreateKeysAndCertificateRequest(input)
  328. err := req.Send()
  329. return out, err
  330. }
  331. const opCreatePolicy = "CreatePolicy"
  332. // CreatePolicyRequest generates a "aws/request.Request" representing the
  333. // client's request for the CreatePolicy operation. The "output" return
  334. // value can be used to capture response data after the request's "Send" method
  335. // is called.
  336. //
  337. // Creating a request object using this method should be used when you want to inject
  338. // custom logic into the request's lifecycle using a custom handler, or if you want to
  339. // access properties on the request object before or after sending the request. If
  340. // you just want the service response, call the CreatePolicy method directly
  341. // instead.
  342. //
  343. // Note: You must call the "Send" method on the returned request object in order
  344. // to execute the request.
  345. //
  346. // // Example sending a request using the CreatePolicyRequest method.
  347. // req, resp := client.CreatePolicyRequest(params)
  348. //
  349. // err := req.Send()
  350. // if err == nil { // resp is now filled
  351. // fmt.Println(resp)
  352. // }
  353. //
  354. func (c *IoT) CreatePolicyRequest(input *CreatePolicyInput) (req *request.Request, output *CreatePolicyOutput) {
  355. op := &request.Operation{
  356. Name: opCreatePolicy,
  357. HTTPMethod: "POST",
  358. HTTPPath: "/policies/{policyName}",
  359. }
  360. if input == nil {
  361. input = &CreatePolicyInput{}
  362. }
  363. req = c.newRequest(op, input, output)
  364. output = &CreatePolicyOutput{}
  365. req.Data = output
  366. return
  367. }
  368. // Creates an AWS IoT policy.
  369. //
  370. // The created policy is the default version for the policy. This operation
  371. // creates a policy version with a version identifier of 1 and sets 1 as the
  372. // policy's default version.
  373. func (c *IoT) CreatePolicy(input *CreatePolicyInput) (*CreatePolicyOutput, error) {
  374. req, out := c.CreatePolicyRequest(input)
  375. err := req.Send()
  376. return out, err
  377. }
  378. const opCreatePolicyVersion = "CreatePolicyVersion"
  379. // CreatePolicyVersionRequest generates a "aws/request.Request" representing the
  380. // client's request for the CreatePolicyVersion operation. The "output" return
  381. // value can be used to capture response data after the request's "Send" method
  382. // is called.
  383. //
  384. // Creating a request object using this method should be used when you want to inject
  385. // custom logic into the request's lifecycle using a custom handler, or if you want to
  386. // access properties on the request object before or after sending the request. If
  387. // you just want the service response, call the CreatePolicyVersion method directly
  388. // instead.
  389. //
  390. // Note: You must call the "Send" method on the returned request object in order
  391. // to execute the request.
  392. //
  393. // // Example sending a request using the CreatePolicyVersionRequest method.
  394. // req, resp := client.CreatePolicyVersionRequest(params)
  395. //
  396. // err := req.Send()
  397. // if err == nil { // resp is now filled
  398. // fmt.Println(resp)
  399. // }
  400. //
  401. func (c *IoT) CreatePolicyVersionRequest(input *CreatePolicyVersionInput) (req *request.Request, output *CreatePolicyVersionOutput) {
  402. op := &request.Operation{
  403. Name: opCreatePolicyVersion,
  404. HTTPMethod: "POST",
  405. HTTPPath: "/policies/{policyName}/version",
  406. }
  407. if input == nil {
  408. input = &CreatePolicyVersionInput{}
  409. }
  410. req = c.newRequest(op, input, output)
  411. output = &CreatePolicyVersionOutput{}
  412. req.Data = output
  413. return
  414. }
  415. // Creates a new version of the specified AWS IoT policy. To update a policy,
  416. // create a new policy version. A managed policy can have up to five versions.
  417. // If the policy has five versions, you must use DeletePolicyVersion to delete
  418. // an existing version before you create a new one.
  419. //
  420. // Optionally, you can set the new version as the policy's default version.
  421. // The default version is the operative version (that is, the version that is
  422. // in effect for the certificates to which the policy is attached).
  423. func (c *IoT) CreatePolicyVersion(input *CreatePolicyVersionInput) (*CreatePolicyVersionOutput, error) {
  424. req, out := c.CreatePolicyVersionRequest(input)
  425. err := req.Send()
  426. return out, err
  427. }
  428. const opCreateThing = "CreateThing"
  429. // CreateThingRequest generates a "aws/request.Request" representing the
  430. // client's request for the CreateThing operation. The "output" return
  431. // value can be used to capture response data after the request's "Send" method
  432. // is called.
  433. //
  434. // Creating a request object using this method should be used when you want to inject
  435. // custom logic into the request's lifecycle using a custom handler, or if you want to
  436. // access properties on the request object before or after sending the request. If
  437. // you just want the service response, call the CreateThing method directly
  438. // instead.
  439. //
  440. // Note: You must call the "Send" method on the returned request object in order
  441. // to execute the request.
  442. //
  443. // // Example sending a request using the CreateThingRequest method.
  444. // req, resp := client.CreateThingRequest(params)
  445. //
  446. // err := req.Send()
  447. // if err == nil { // resp is now filled
  448. // fmt.Println(resp)
  449. // }
  450. //
  451. func (c *IoT) CreateThingRequest(input *CreateThingInput) (req *request.Request, output *CreateThingOutput) {
  452. op := &request.Operation{
  453. Name: opCreateThing,
  454. HTTPMethod: "POST",
  455. HTTPPath: "/things/{thingName}",
  456. }
  457. if input == nil {
  458. input = &CreateThingInput{}
  459. }
  460. req = c.newRequest(op, input, output)
  461. output = &CreateThingOutput{}
  462. req.Data = output
  463. return
  464. }
  465. // Creates a thing record in the thing registry.
  466. func (c *IoT) CreateThing(input *CreateThingInput) (*CreateThingOutput, error) {
  467. req, out := c.CreateThingRequest(input)
  468. err := req.Send()
  469. return out, err
  470. }
  471. const opCreateThingType = "CreateThingType"
  472. // CreateThingTypeRequest generates a "aws/request.Request" representing the
  473. // client's request for the CreateThingType operation. The "output" return
  474. // value can be used to capture response data after the request's "Send" method
  475. // is called.
  476. //
  477. // Creating a request object using this method should be used when you want to inject
  478. // custom logic into the request's lifecycle using a custom handler, or if you want to
  479. // access properties on the request object before or after sending the request. If
  480. // you just want the service response, call the CreateThingType method directly
  481. // instead.
  482. //
  483. // Note: You must call the "Send" method on the returned request object in order
  484. // to execute the request.
  485. //
  486. // // Example sending a request using the CreateThingTypeRequest method.
  487. // req, resp := client.CreateThingTypeRequest(params)
  488. //
  489. // err := req.Send()
  490. // if err == nil { // resp is now filled
  491. // fmt.Println(resp)
  492. // }
  493. //
  494. func (c *IoT) CreateThingTypeRequest(input *CreateThingTypeInput) (req *request.Request, output *CreateThingTypeOutput) {
  495. op := &request.Operation{
  496. Name: opCreateThingType,
  497. HTTPMethod: "POST",
  498. HTTPPath: "/thing-types/{thingTypeName}",
  499. }
  500. if input == nil {
  501. input = &CreateThingTypeInput{}
  502. }
  503. req = c.newRequest(op, input, output)
  504. output = &CreateThingTypeOutput{}
  505. req.Data = output
  506. return
  507. }
  508. // Creates a new thing type.
  509. func (c *IoT) CreateThingType(input *CreateThingTypeInput) (*CreateThingTypeOutput, error) {
  510. req, out := c.CreateThingTypeRequest(input)
  511. err := req.Send()
  512. return out, err
  513. }
  514. const opCreateTopicRule = "CreateTopicRule"
  515. // CreateTopicRuleRequest generates a "aws/request.Request" representing the
  516. // client's request for the CreateTopicRule operation. The "output" return
  517. // value can be used to capture response data after the request's "Send" method
  518. // is called.
  519. //
  520. // Creating a request object using this method should be used when you want to inject
  521. // custom logic into the request's lifecycle using a custom handler, or if you want to
  522. // access properties on the request object before or after sending the request. If
  523. // you just want the service response, call the CreateTopicRule method directly
  524. // instead.
  525. //
  526. // Note: You must call the "Send" method on the returned request object in order
  527. // to execute the request.
  528. //
  529. // // Example sending a request using the CreateTopicRuleRequest method.
  530. // req, resp := client.CreateTopicRuleRequest(params)
  531. //
  532. // err := req.Send()
  533. // if err == nil { // resp is now filled
  534. // fmt.Println(resp)
  535. // }
  536. //
  537. func (c *IoT) CreateTopicRuleRequest(input *CreateTopicRuleInput) (req *request.Request, output *CreateTopicRuleOutput) {
  538. op := &request.Operation{
  539. Name: opCreateTopicRule,
  540. HTTPMethod: "POST",
  541. HTTPPath: "/rules/{ruleName}",
  542. }
  543. if input == nil {
  544. input = &CreateTopicRuleInput{}
  545. }
  546. req = c.newRequest(op, input, output)
  547. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  548. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  549. output = &CreateTopicRuleOutput{}
  550. req.Data = output
  551. return
  552. }
  553. // Creates a rule. Creating rules is an administrator-level action. Any user
  554. // who has permission to create rules will be able to access data processed
  555. // by the rule.
  556. func (c *IoT) CreateTopicRule(input *CreateTopicRuleInput) (*CreateTopicRuleOutput, error) {
  557. req, out := c.CreateTopicRuleRequest(input)
  558. err := req.Send()
  559. return out, err
  560. }
  561. const opDeleteCACertificate = "DeleteCACertificate"
  562. // DeleteCACertificateRequest generates a "aws/request.Request" representing the
  563. // client's request for the DeleteCACertificate operation. The "output" return
  564. // value can be used to capture response data after the request's "Send" method
  565. // is called.
  566. //
  567. // Creating a request object using this method should be used when you want to inject
  568. // custom logic into the request's lifecycle using a custom handler, or if you want to
  569. // access properties on the request object before or after sending the request. If
  570. // you just want the service response, call the DeleteCACertificate method directly
  571. // instead.
  572. //
  573. // Note: You must call the "Send" method on the returned request object in order
  574. // to execute the request.
  575. //
  576. // // Example sending a request using the DeleteCACertificateRequest method.
  577. // req, resp := client.DeleteCACertificateRequest(params)
  578. //
  579. // err := req.Send()
  580. // if err == nil { // resp is now filled
  581. // fmt.Println(resp)
  582. // }
  583. //
  584. func (c *IoT) DeleteCACertificateRequest(input *DeleteCACertificateInput) (req *request.Request, output *DeleteCACertificateOutput) {
  585. op := &request.Operation{
  586. Name: opDeleteCACertificate,
  587. HTTPMethod: "DELETE",
  588. HTTPPath: "/cacertificate/{caCertificateId}",
  589. }
  590. if input == nil {
  591. input = &DeleteCACertificateInput{}
  592. }
  593. req = c.newRequest(op, input, output)
  594. output = &DeleteCACertificateOutput{}
  595. req.Data = output
  596. return
  597. }
  598. // Deletes a registered CA certificate.
  599. func (c *IoT) DeleteCACertificate(input *DeleteCACertificateInput) (*DeleteCACertificateOutput, error) {
  600. req, out := c.DeleteCACertificateRequest(input)
  601. err := req.Send()
  602. return out, err
  603. }
  604. const opDeleteCertificate = "DeleteCertificate"
  605. // DeleteCertificateRequest generates a "aws/request.Request" representing the
  606. // client's request for the DeleteCertificate operation. The "output" return
  607. // value can be used to capture response data after the request's "Send" method
  608. // is called.
  609. //
  610. // Creating a request object using this method should be used when you want to inject
  611. // custom logic into the request's lifecycle using a custom handler, or if you want to
  612. // access properties on the request object before or after sending the request. If
  613. // you just want the service response, call the DeleteCertificate method directly
  614. // instead.
  615. //
  616. // Note: You must call the "Send" method on the returned request object in order
  617. // to execute the request.
  618. //
  619. // // Example sending a request using the DeleteCertificateRequest method.
  620. // req, resp := client.DeleteCertificateRequest(params)
  621. //
  622. // err := req.Send()
  623. // if err == nil { // resp is now filled
  624. // fmt.Println(resp)
  625. // }
  626. //
  627. func (c *IoT) DeleteCertificateRequest(input *DeleteCertificateInput) (req *request.Request, output *DeleteCertificateOutput) {
  628. op := &request.Operation{
  629. Name: opDeleteCertificate,
  630. HTTPMethod: "DELETE",
  631. HTTPPath: "/certificates/{certificateId}",
  632. }
  633. if input == nil {
  634. input = &DeleteCertificateInput{}
  635. }
  636. req = c.newRequest(op, input, output)
  637. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  638. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  639. output = &DeleteCertificateOutput{}
  640. req.Data = output
  641. return
  642. }
  643. // Deletes the specified certificate.
  644. //
  645. // A certificate cannot be deleted if it has a policy attached to it or if
  646. // its status is set to ACTIVE. To delete a certificate, first use the DetachPrincipalPolicy
  647. // API to detach all policies. Next, use the UpdateCertificate API to set the
  648. // certificate to the INACTIVE status.
  649. func (c *IoT) DeleteCertificate(input *DeleteCertificateInput) (*DeleteCertificateOutput, error) {
  650. req, out := c.DeleteCertificateRequest(input)
  651. err := req.Send()
  652. return out, err
  653. }
  654. const opDeletePolicy = "DeletePolicy"
  655. // DeletePolicyRequest generates a "aws/request.Request" representing the
  656. // client's request for the DeletePolicy operation. The "output" return
  657. // value can be used to capture response data after the request's "Send" method
  658. // is called.
  659. //
  660. // Creating a request object using this method should be used when you want to inject
  661. // custom logic into the request's lifecycle using a custom handler, or if you want to
  662. // access properties on the request object before or after sending the request. If
  663. // you just want the service response, call the DeletePolicy method directly
  664. // instead.
  665. //
  666. // Note: You must call the "Send" method on the returned request object in order
  667. // to execute the request.
  668. //
  669. // // Example sending a request using the DeletePolicyRequest method.
  670. // req, resp := client.DeletePolicyRequest(params)
  671. //
  672. // err := req.Send()
  673. // if err == nil { // resp is now filled
  674. // fmt.Println(resp)
  675. // }
  676. //
  677. func (c *IoT) DeletePolicyRequest(input *DeletePolicyInput) (req *request.Request, output *DeletePolicyOutput) {
  678. op := &request.Operation{
  679. Name: opDeletePolicy,
  680. HTTPMethod: "DELETE",
  681. HTTPPath: "/policies/{policyName}",
  682. }
  683. if input == nil {
  684. input = &DeletePolicyInput{}
  685. }
  686. req = c.newRequest(op, input, output)
  687. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  688. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  689. output = &DeletePolicyOutput{}
  690. req.Data = output
  691. return
  692. }
  693. // Deletes the specified policy.
  694. //
  695. // A policy cannot be deleted if it has non-default versions or it is attached
  696. // to any certificate.
  697. //
  698. // To delete a policy, use the DeletePolicyVersion API to delete all non-default
  699. // versions of the policy; use the DetachPrincipalPolicy API to detach the policy
  700. // from any certificate; and then use the DeletePolicy API to delete the policy.
  701. //
  702. // When a policy is deleted using DeletePolicy, its default version is deleted
  703. // with it.
  704. func (c *IoT) DeletePolicy(input *DeletePolicyInput) (*DeletePolicyOutput, error) {
  705. req, out := c.DeletePolicyRequest(input)
  706. err := req.Send()
  707. return out, err
  708. }
  709. const opDeletePolicyVersion = "DeletePolicyVersion"
  710. // DeletePolicyVersionRequest generates a "aws/request.Request" representing the
  711. // client's request for the DeletePolicyVersion operation. The "output" return
  712. // value can be used to capture response data after the request's "Send" method
  713. // is called.
  714. //
  715. // Creating a request object using this method should be used when you want to inject
  716. // custom logic into the request's lifecycle using a custom handler, or if you want to
  717. // access properties on the request object before or after sending the request. If
  718. // you just want the service response, call the DeletePolicyVersion method directly
  719. // instead.
  720. //
  721. // Note: You must call the "Send" method on the returned request object in order
  722. // to execute the request.
  723. //
  724. // // Example sending a request using the DeletePolicyVersionRequest method.
  725. // req, resp := client.DeletePolicyVersionRequest(params)
  726. //
  727. // err := req.Send()
  728. // if err == nil { // resp is now filled
  729. // fmt.Println(resp)
  730. // }
  731. //
  732. func (c *IoT) DeletePolicyVersionRequest(input *DeletePolicyVersionInput) (req *request.Request, output *DeletePolicyVersionOutput) {
  733. op := &request.Operation{
  734. Name: opDeletePolicyVersion,
  735. HTTPMethod: "DELETE",
  736. HTTPPath: "/policies/{policyName}/version/{policyVersionId}",
  737. }
  738. if input == nil {
  739. input = &DeletePolicyVersionInput{}
  740. }
  741. req = c.newRequest(op, input, output)
  742. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  743. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  744. output = &DeletePolicyVersionOutput{}
  745. req.Data = output
  746. return
  747. }
  748. // Deletes the specified version of the specified policy. You cannot delete
  749. // the default version of a policy using this API. To delete the default version
  750. // of a policy, use DeletePolicy. To find out which version of a policy is marked
  751. // as the default version, use ListPolicyVersions.
  752. func (c *IoT) DeletePolicyVersion(input *DeletePolicyVersionInput) (*DeletePolicyVersionOutput, error) {
  753. req, out := c.DeletePolicyVersionRequest(input)
  754. err := req.Send()
  755. return out, err
  756. }
  757. const opDeleteRegistrationCode = "DeleteRegistrationCode"
  758. // DeleteRegistrationCodeRequest generates a "aws/request.Request" representing the
  759. // client's request for the DeleteRegistrationCode operation. The "output" return
  760. // value can be used to capture response data after the request's "Send" method
  761. // is called.
  762. //
  763. // Creating a request object using this method should be used when you want to inject
  764. // custom logic into the request's lifecycle using a custom handler, or if you want to
  765. // access properties on the request object before or after sending the request. If
  766. // you just want the service response, call the DeleteRegistrationCode method directly
  767. // instead.
  768. //
  769. // Note: You must call the "Send" method on the returned request object in order
  770. // to execute the request.
  771. //
  772. // // Example sending a request using the DeleteRegistrationCodeRequest method.
  773. // req, resp := client.DeleteRegistrationCodeRequest(params)
  774. //
  775. // err := req.Send()
  776. // if err == nil { // resp is now filled
  777. // fmt.Println(resp)
  778. // }
  779. //
  780. func (c *IoT) DeleteRegistrationCodeRequest(input *DeleteRegistrationCodeInput) (req *request.Request, output *DeleteRegistrationCodeOutput) {
  781. op := &request.Operation{
  782. Name: opDeleteRegistrationCode,
  783. HTTPMethod: "DELETE",
  784. HTTPPath: "/registrationcode",
  785. }
  786. if input == nil {
  787. input = &DeleteRegistrationCodeInput{}
  788. }
  789. req = c.newRequest(op, input, output)
  790. output = &DeleteRegistrationCodeOutput{}
  791. req.Data = output
  792. return
  793. }
  794. // Deletes a CA certificate registration code.
  795. func (c *IoT) DeleteRegistrationCode(input *DeleteRegistrationCodeInput) (*DeleteRegistrationCodeOutput, error) {
  796. req, out := c.DeleteRegistrationCodeRequest(input)
  797. err := req.Send()
  798. return out, err
  799. }
  800. const opDeleteThing = "DeleteThing"
  801. // DeleteThingRequest generates a "aws/request.Request" representing the
  802. // client's request for the DeleteThing operation. The "output" return
  803. // value can be used to capture response data after the request's "Send" method
  804. // is called.
  805. //
  806. // Creating a request object using this method should be used when you want to inject
  807. // custom logic into the request's lifecycle using a custom handler, or if you want to
  808. // access properties on the request object before or after sending the request. If
  809. // you just want the service response, call the DeleteThing method directly
  810. // instead.
  811. //
  812. // Note: You must call the "Send" method on the returned request object in order
  813. // to execute the request.
  814. //
  815. // // Example sending a request using the DeleteThingRequest method.
  816. // req, resp := client.DeleteThingRequest(params)
  817. //
  818. // err := req.Send()
  819. // if err == nil { // resp is now filled
  820. // fmt.Println(resp)
  821. // }
  822. //
  823. func (c *IoT) DeleteThingRequest(input *DeleteThingInput) (req *request.Request, output *DeleteThingOutput) {
  824. op := &request.Operation{
  825. Name: opDeleteThing,
  826. HTTPMethod: "DELETE",
  827. HTTPPath: "/things/{thingName}",
  828. }
  829. if input == nil {
  830. input = &DeleteThingInput{}
  831. }
  832. req = c.newRequest(op, input, output)
  833. output = &DeleteThingOutput{}
  834. req.Data = output
  835. return
  836. }
  837. // Deletes the specified thing.
  838. func (c *IoT) DeleteThing(input *DeleteThingInput) (*DeleteThingOutput, error) {
  839. req, out := c.DeleteThingRequest(input)
  840. err := req.Send()
  841. return out, err
  842. }
  843. const opDeleteThingType = "DeleteThingType"
  844. // DeleteThingTypeRequest generates a "aws/request.Request" representing the
  845. // client's request for the DeleteThingType operation. The "output" return
  846. // value can be used to capture response data after the request's "Send" method
  847. // is called.
  848. //
  849. // Creating a request object using this method should be used when you want to inject
  850. // custom logic into the request's lifecycle using a custom handler, or if you want to
  851. // access properties on the request object before or after sending the request. If
  852. // you just want the service response, call the DeleteThingType method directly
  853. // instead.
  854. //
  855. // Note: You must call the "Send" method on the returned request object in order
  856. // to execute the request.
  857. //
  858. // // Example sending a request using the DeleteThingTypeRequest method.
  859. // req, resp := client.DeleteThingTypeRequest(params)
  860. //
  861. // err := req.Send()
  862. // if err == nil { // resp is now filled
  863. // fmt.Println(resp)
  864. // }
  865. //
  866. func (c *IoT) DeleteThingTypeRequest(input *DeleteThingTypeInput) (req *request.Request, output *DeleteThingTypeOutput) {
  867. op := &request.Operation{
  868. Name: opDeleteThingType,
  869. HTTPMethod: "DELETE",
  870. HTTPPath: "/thing-types/{thingTypeName}",
  871. }
  872. if input == nil {
  873. input = &DeleteThingTypeInput{}
  874. }
  875. req = c.newRequest(op, input, output)
  876. output = &DeleteThingTypeOutput{}
  877. req.Data = output
  878. return
  879. }
  880. // Deletes the specified thing type . You cannot delete a thing type if it has
  881. // things associated with it. To delete a thing type, first mark it as deprecated
  882. // by calling DeprecateThingType, then remove any associated things by calling
  883. // UpdateThing to change the thing type on any associated thing, and finally
  884. // use DeleteThingType to delete the thing type.
  885. func (c *IoT) DeleteThingType(input *DeleteThingTypeInput) (*DeleteThingTypeOutput, error) {
  886. req, out := c.DeleteThingTypeRequest(input)
  887. err := req.Send()
  888. return out, err
  889. }
  890. const opDeleteTopicRule = "DeleteTopicRule"
  891. // DeleteTopicRuleRequest generates a "aws/request.Request" representing the
  892. // client's request for the DeleteTopicRule operation. The "output" return
  893. // value can be used to capture response data after the request's "Send" method
  894. // is called.
  895. //
  896. // Creating a request object using this method should be used when you want to inject
  897. // custom logic into the request's lifecycle using a custom handler, or if you want to
  898. // access properties on the request object before or after sending the request. If
  899. // you just want the service response, call the DeleteTopicRule method directly
  900. // instead.
  901. //
  902. // Note: You must call the "Send" method on the returned request object in order
  903. // to execute the request.
  904. //
  905. // // Example sending a request using the DeleteTopicRuleRequest method.
  906. // req, resp := client.DeleteTopicRuleRequest(params)
  907. //
  908. // err := req.Send()
  909. // if err == nil { // resp is now filled
  910. // fmt.Println(resp)
  911. // }
  912. //
  913. func (c *IoT) DeleteTopicRuleRequest(input *DeleteTopicRuleInput) (req *request.Request, output *DeleteTopicRuleOutput) {
  914. op := &request.Operation{
  915. Name: opDeleteTopicRule,
  916. HTTPMethod: "DELETE",
  917. HTTPPath: "/rules/{ruleName}",
  918. }
  919. if input == nil {
  920. input = &DeleteTopicRuleInput{}
  921. }
  922. req = c.newRequest(op, input, output)
  923. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  924. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  925. output = &DeleteTopicRuleOutput{}
  926. req.Data = output
  927. return
  928. }
  929. // Deletes the specified rule.
  930. func (c *IoT) DeleteTopicRule(input *DeleteTopicRuleInput) (*DeleteTopicRuleOutput, error) {
  931. req, out := c.DeleteTopicRuleRequest(input)
  932. err := req.Send()
  933. return out, err
  934. }
  935. const opDeprecateThingType = "DeprecateThingType"
  936. // DeprecateThingTypeRequest generates a "aws/request.Request" representing the
  937. // client's request for the DeprecateThingType operation. The "output" return
  938. // value can be used to capture response data after the request's "Send" method
  939. // is called.
  940. //
  941. // Creating a request object using this method should be used when you want to inject
  942. // custom logic into the request's lifecycle using a custom handler, or if you want to
  943. // access properties on the request object before or after sending the request. If
  944. // you just want the service response, call the DeprecateThingType method directly
  945. // instead.
  946. //
  947. // Note: You must call the "Send" method on the returned request object in order
  948. // to execute the request.
  949. //
  950. // // Example sending a request using the DeprecateThingTypeRequest method.
  951. // req, resp := client.DeprecateThingTypeRequest(params)
  952. //
  953. // err := req.Send()
  954. // if err == nil { // resp is now filled
  955. // fmt.Println(resp)
  956. // }
  957. //
  958. func (c *IoT) DeprecateThingTypeRequest(input *DeprecateThingTypeInput) (req *request.Request, output *DeprecateThingTypeOutput) {
  959. op := &request.Operation{
  960. Name: opDeprecateThingType,
  961. HTTPMethod: "POST",
  962. HTTPPath: "/thing-types/{thingTypeName}/deprecate",
  963. }
  964. if input == nil {
  965. input = &DeprecateThingTypeInput{}
  966. }
  967. req = c.newRequest(op, input, output)
  968. output = &DeprecateThingTypeOutput{}
  969. req.Data = output
  970. return
  971. }
  972. // Deprecates a thing type. You can not associate new things with deprecated
  973. // thing type.
  974. func (c *IoT) DeprecateThingType(input *DeprecateThingTypeInput) (*DeprecateThingTypeOutput, error) {
  975. req, out := c.DeprecateThingTypeRequest(input)
  976. err := req.Send()
  977. return out, err
  978. }
  979. const opDescribeCACertificate = "DescribeCACertificate"
  980. // DescribeCACertificateRequest generates a "aws/request.Request" representing the
  981. // client's request for the DescribeCACertificate operation. The "output" return
  982. // value can be used to capture response data after the request's "Send" method
  983. // is called.
  984. //
  985. // Creating a request object using this method should be used when you want to inject
  986. // custom logic into the request's lifecycle using a custom handler, or if you want to
  987. // access properties on the request object before or after sending the request. If
  988. // you just want the service response, call the DescribeCACertificate method directly
  989. // instead.
  990. //
  991. // Note: You must call the "Send" method on the returned request object in order
  992. // to execute the request.
  993. //
  994. // // Example sending a request using the DescribeCACertificateRequest method.
  995. // req, resp := client.DescribeCACertificateRequest(params)
  996. //
  997. // err := req.Send()
  998. // if err == nil { // resp is now filled
  999. // fmt.Println(resp)
  1000. // }
  1001. //
  1002. func (c *IoT) DescribeCACertificateRequest(input *DescribeCACertificateInput) (req *request.Request, output *DescribeCACertificateOutput) {
  1003. op := &request.Operation{
  1004. Name: opDescribeCACertificate,
  1005. HTTPMethod: "GET",
  1006. HTTPPath: "/cacertificate/{caCertificateId}",
  1007. }
  1008. if input == nil {
  1009. input = &DescribeCACertificateInput{}
  1010. }
  1011. req = c.newRequest(op, input, output)
  1012. output = &DescribeCACertificateOutput{}
  1013. req.Data = output
  1014. return
  1015. }
  1016. // Describes a registered CA certificate.
  1017. func (c *IoT) DescribeCACertificate(input *DescribeCACertificateInput) (*DescribeCACertificateOutput, error) {
  1018. req, out := c.DescribeCACertificateRequest(input)
  1019. err := req.Send()
  1020. return out, err
  1021. }
  1022. const opDescribeCertificate = "DescribeCertificate"
  1023. // DescribeCertificateRequest generates a "aws/request.Request" representing the
  1024. // client's request for the DescribeCertificate operation. The "output" return
  1025. // value can be used to capture response data after the request's "Send" method
  1026. // is called.
  1027. //
  1028. // Creating a request object using this method should be used when you want to inject
  1029. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1030. // access properties on the request object before or after sending the request. If
  1031. // you just want the service response, call the DescribeCertificate method directly
  1032. // instead.
  1033. //
  1034. // Note: You must call the "Send" method on the returned request object in order
  1035. // to execute the request.
  1036. //
  1037. // // Example sending a request using the DescribeCertificateRequest method.
  1038. // req, resp := client.DescribeCertificateRequest(params)
  1039. //
  1040. // err := req.Send()
  1041. // if err == nil { // resp is now filled
  1042. // fmt.Println(resp)
  1043. // }
  1044. //
  1045. func (c *IoT) DescribeCertificateRequest(input *DescribeCertificateInput) (req *request.Request, output *DescribeCertificateOutput) {
  1046. op := &request.Operation{
  1047. Name: opDescribeCertificate,
  1048. HTTPMethod: "GET",
  1049. HTTPPath: "/certificates/{certificateId}",
  1050. }
  1051. if input == nil {
  1052. input = &DescribeCertificateInput{}
  1053. }
  1054. req = c.newRequest(op, input, output)
  1055. output = &DescribeCertificateOutput{}
  1056. req.Data = output
  1057. return
  1058. }
  1059. // Gets information about the specified certificate.
  1060. func (c *IoT) DescribeCertificate(input *DescribeCertificateInput) (*DescribeCertificateOutput, error) {
  1061. req, out := c.DescribeCertificateRequest(input)
  1062. err := req.Send()
  1063. return out, err
  1064. }
  1065. const opDescribeEndpoint = "DescribeEndpoint"
  1066. // DescribeEndpointRequest generates a "aws/request.Request" representing the
  1067. // client's request for the DescribeEndpoint operation. The "output" return
  1068. // value can be used to capture response data after the request's "Send" method
  1069. // is called.
  1070. //
  1071. // Creating a request object using this method should be used when you want to inject
  1072. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1073. // access properties on the request object before or after sending the request. If
  1074. // you just want the service response, call the DescribeEndpoint method directly
  1075. // instead.
  1076. //
  1077. // Note: You must call the "Send" method on the returned request object in order
  1078. // to execute the request.
  1079. //
  1080. // // Example sending a request using the DescribeEndpointRequest method.
  1081. // req, resp := client.DescribeEndpointRequest(params)
  1082. //
  1083. // err := req.Send()
  1084. // if err == nil { // resp is now filled
  1085. // fmt.Println(resp)
  1086. // }
  1087. //
  1088. func (c *IoT) DescribeEndpointRequest(input *DescribeEndpointInput) (req *request.Request, output *DescribeEndpointOutput) {
  1089. op := &request.Operation{
  1090. Name: opDescribeEndpoint,
  1091. HTTPMethod: "GET",
  1092. HTTPPath: "/endpoint",
  1093. }
  1094. if input == nil {
  1095. input = &DescribeEndpointInput{}
  1096. }
  1097. req = c.newRequest(op, input, output)
  1098. output = &DescribeEndpointOutput{}
  1099. req.Data = output
  1100. return
  1101. }
  1102. // Returns a unique endpoint specific to the AWS account making the call.
  1103. func (c *IoT) DescribeEndpoint(input *DescribeEndpointInput) (*DescribeEndpointOutput, error) {
  1104. req, out := c.DescribeEndpointRequest(input)
  1105. err := req.Send()
  1106. return out, err
  1107. }
  1108. const opDescribeThing = "DescribeThing"
  1109. // DescribeThingRequest generates a "aws/request.Request" representing the
  1110. // client's request for the DescribeThing operation. The "output" return
  1111. // value can be used to capture response data after the request's "Send" method
  1112. // is called.
  1113. //
  1114. // Creating a request object using this method should be used when you want to inject
  1115. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1116. // access properties on the request object before or after sending the request. If
  1117. // you just want the service response, call the DescribeThing method directly
  1118. // instead.
  1119. //
  1120. // Note: You must call the "Send" method on the returned request object in order
  1121. // to execute the request.
  1122. //
  1123. // // Example sending a request using the DescribeThingRequest method.
  1124. // req, resp := client.DescribeThingRequest(params)
  1125. //
  1126. // err := req.Send()
  1127. // if err == nil { // resp is now filled
  1128. // fmt.Println(resp)
  1129. // }
  1130. //
  1131. func (c *IoT) DescribeThingRequest(input *DescribeThingInput) (req *request.Request, output *DescribeThingOutput) {
  1132. op := &request.Operation{
  1133. Name: opDescribeThing,
  1134. HTTPMethod: "GET",
  1135. HTTPPath: "/things/{thingName}",
  1136. }
  1137. if input == nil {
  1138. input = &DescribeThingInput{}
  1139. }
  1140. req = c.newRequest(op, input, output)
  1141. output = &DescribeThingOutput{}
  1142. req.Data = output
  1143. return
  1144. }
  1145. // Gets information about the specified thing.
  1146. func (c *IoT) DescribeThing(input *DescribeThingInput) (*DescribeThingOutput, error) {
  1147. req, out := c.DescribeThingRequest(input)
  1148. err := req.Send()
  1149. return out, err
  1150. }
  1151. const opDescribeThingType = "DescribeThingType"
  1152. // DescribeThingTypeRequest generates a "aws/request.Request" representing the
  1153. // client's request for the DescribeThingType operation. The "output" return
  1154. // value can be used to capture response data after the request's "Send" method
  1155. // is called.
  1156. //
  1157. // Creating a request object using this method should be used when you want to inject
  1158. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1159. // access properties on the request object before or after sending the request. If
  1160. // you just want the service response, call the DescribeThingType method directly
  1161. // instead.
  1162. //
  1163. // Note: You must call the "Send" method on the returned request object in order
  1164. // to execute the request.
  1165. //
  1166. // // Example sending a request using the DescribeThingTypeRequest method.
  1167. // req, resp := client.DescribeThingTypeRequest(params)
  1168. //
  1169. // err := req.Send()
  1170. // if err == nil { // resp is now filled
  1171. // fmt.Println(resp)
  1172. // }
  1173. //
  1174. func (c *IoT) DescribeThingTypeRequest(input *DescribeThingTypeInput) (req *request.Request, output *DescribeThingTypeOutput) {
  1175. op := &request.Operation{
  1176. Name: opDescribeThingType,
  1177. HTTPMethod: "GET",
  1178. HTTPPath: "/thing-types/{thingTypeName}",
  1179. }
  1180. if input == nil {
  1181. input = &DescribeThingTypeInput{}
  1182. }
  1183. req = c.newRequest(op, input, output)
  1184. output = &DescribeThingTypeOutput{}
  1185. req.Data = output
  1186. return
  1187. }
  1188. // Gets information about the specified thing type.
  1189. func (c *IoT) DescribeThingType(input *DescribeThingTypeInput) (*DescribeThingTypeOutput, error) {
  1190. req, out := c.DescribeThingTypeRequest(input)
  1191. err := req.Send()
  1192. return out, err
  1193. }
  1194. const opDetachPrincipalPolicy = "DetachPrincipalPolicy"
  1195. // DetachPrincipalPolicyRequest generates a "aws/request.Request" representing the
  1196. // client's request for the DetachPrincipalPolicy operation. The "output" return
  1197. // value can be used to capture response data after the request's "Send" method
  1198. // is called.
  1199. //
  1200. // Creating a request object using this method should be used when you want to inject
  1201. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1202. // access properties on the request object before or after sending the request. If
  1203. // you just want the service response, call the DetachPrincipalPolicy method directly
  1204. // instead.
  1205. //
  1206. // Note: You must call the "Send" method on the returned request object in order
  1207. // to execute the request.
  1208. //
  1209. // // Example sending a request using the DetachPrincipalPolicyRequest method.
  1210. // req, resp := client.DetachPrincipalPolicyRequest(params)
  1211. //
  1212. // err := req.Send()
  1213. // if err == nil { // resp is now filled
  1214. // fmt.Println(resp)
  1215. // }
  1216. //
  1217. func (c *IoT) DetachPrincipalPolicyRequest(input *DetachPrincipalPolicyInput) (req *request.Request, output *DetachPrincipalPolicyOutput) {
  1218. op := &request.Operation{
  1219. Name: opDetachPrincipalPolicy,
  1220. HTTPMethod: "DELETE",
  1221. HTTPPath: "/principal-policies/{policyName}",
  1222. }
  1223. if input == nil {
  1224. input = &DetachPrincipalPolicyInput{}
  1225. }
  1226. req = c.newRequest(op, input, output)
  1227. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  1228. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  1229. output = &DetachPrincipalPolicyOutput{}
  1230. req.Data = output
  1231. return
  1232. }
  1233. // Removes the specified policy from the specified certificate.
  1234. func (c *IoT) DetachPrincipalPolicy(input *DetachPrincipalPolicyInput) (*DetachPrincipalPolicyOutput, error) {
  1235. req, out := c.DetachPrincipalPolicyRequest(input)
  1236. err := req.Send()
  1237. return out, err
  1238. }
  1239. const opDetachThingPrincipal = "DetachThingPrincipal"
  1240. // DetachThingPrincipalRequest generates a "aws/request.Request" representing the
  1241. // client's request for the DetachThingPrincipal operation. The "output" return
  1242. // value can be used to capture response data after the request's "Send" method
  1243. // is called.
  1244. //
  1245. // Creating a request object using this method should be used when you want to inject
  1246. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1247. // access properties on the request object before or after sending the request. If
  1248. // you just want the service response, call the DetachThingPrincipal method directly
  1249. // instead.
  1250. //
  1251. // Note: You must call the "Send" method on the returned request object in order
  1252. // to execute the request.
  1253. //
  1254. // // Example sending a request using the DetachThingPrincipalRequest method.
  1255. // req, resp := client.DetachThingPrincipalRequest(params)
  1256. //
  1257. // err := req.Send()
  1258. // if err == nil { // resp is now filled
  1259. // fmt.Println(resp)
  1260. // }
  1261. //
  1262. func (c *IoT) DetachThingPrincipalRequest(input *DetachThingPrincipalInput) (req *request.Request, output *DetachThingPrincipalOutput) {
  1263. op := &request.Operation{
  1264. Name: opDetachThingPrincipal,
  1265. HTTPMethod: "DELETE",
  1266. HTTPPath: "/things/{thingName}/principals",
  1267. }
  1268. if input == nil {
  1269. input = &DetachThingPrincipalInput{}
  1270. }
  1271. req = c.newRequest(op, input, output)
  1272. output = &DetachThingPrincipalOutput{}
  1273. req.Data = output
  1274. return
  1275. }
  1276. // Detaches the specified principal from the specified thing.
  1277. func (c *IoT) DetachThingPrincipal(input *DetachThingPrincipalInput) (*DetachThingPrincipalOutput, error) {
  1278. req, out := c.DetachThingPrincipalRequest(input)
  1279. err := req.Send()
  1280. return out, err
  1281. }
  1282. const opDisableTopicRule = "DisableTopicRule"
  1283. // DisableTopicRuleRequest generates a "aws/request.Request" representing the
  1284. // client's request for the DisableTopicRule operation. The "output" return
  1285. // value can be used to capture response data after the request's "Send" method
  1286. // is called.
  1287. //
  1288. // Creating a request object using this method should be used when you want to inject
  1289. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1290. // access properties on the request object before or after sending the request. If
  1291. // you just want the service response, call the DisableTopicRule method directly
  1292. // instead.
  1293. //
  1294. // Note: You must call the "Send" method on the returned request object in order
  1295. // to execute the request.
  1296. //
  1297. // // Example sending a request using the DisableTopicRuleRequest method.
  1298. // req, resp := client.DisableTopicRuleRequest(params)
  1299. //
  1300. // err := req.Send()
  1301. // if err == nil { // resp is now filled
  1302. // fmt.Println(resp)
  1303. // }
  1304. //
  1305. func (c *IoT) DisableTopicRuleRequest(input *DisableTopicRuleInput) (req *request.Request, output *DisableTopicRuleOutput) {
  1306. op := &request.Operation{
  1307. Name: opDisableTopicRule,
  1308. HTTPMethod: "POST",
  1309. HTTPPath: "/rules/{ruleName}/disable",
  1310. }
  1311. if input == nil {
  1312. input = &DisableTopicRuleInput{}
  1313. }
  1314. req = c.newRequest(op, input, output)
  1315. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  1316. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  1317. output = &DisableTopicRuleOutput{}
  1318. req.Data = output
  1319. return
  1320. }
  1321. // Disables the specified rule.
  1322. func (c *IoT) DisableTopicRule(input *DisableTopicRuleInput) (*DisableTopicRuleOutput, error) {
  1323. req, out := c.DisableTopicRuleRequest(input)
  1324. err := req.Send()
  1325. return out, err
  1326. }
  1327. const opEnableTopicRule = "EnableTopicRule"
  1328. // EnableTopicRuleRequest generates a "aws/request.Request" representing the
  1329. // client's request for the EnableTopicRule operation. The "output" return
  1330. // value can be used to capture response data after the request's "Send" method
  1331. // is called.
  1332. //
  1333. // Creating a request object using this method should be used when you want to inject
  1334. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1335. // access properties on the request object before or after sending the request. If
  1336. // you just want the service response, call the EnableTopicRule method directly
  1337. // instead.
  1338. //
  1339. // Note: You must call the "Send" method on the returned request object in order
  1340. // to execute the request.
  1341. //
  1342. // // Example sending a request using the EnableTopicRuleRequest method.
  1343. // req, resp := client.EnableTopicRuleRequest(params)
  1344. //
  1345. // err := req.Send()
  1346. // if err == nil { // resp is now filled
  1347. // fmt.Println(resp)
  1348. // }
  1349. //
  1350. func (c *IoT) EnableTopicRuleRequest(input *EnableTopicRuleInput) (req *request.Request, output *EnableTopicRuleOutput) {
  1351. op := &request.Operation{
  1352. Name: opEnableTopicRule,
  1353. HTTPMethod: "POST",
  1354. HTTPPath: "/rules/{ruleName}/enable",
  1355. }
  1356. if input == nil {
  1357. input = &EnableTopicRuleInput{}
  1358. }
  1359. req = c.newRequest(op, input, output)
  1360. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  1361. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  1362. output = &EnableTopicRuleOutput{}
  1363. req.Data = output
  1364. return
  1365. }
  1366. // Enables the specified rule.
  1367. func (c *IoT) EnableTopicRule(input *EnableTopicRuleInput) (*EnableTopicRuleOutput, error) {
  1368. req, out := c.EnableTopicRuleRequest(input)
  1369. err := req.Send()
  1370. return out, err
  1371. }
  1372. const opGetLoggingOptions = "GetLoggingOptions"
  1373. // GetLoggingOptionsRequest generates a "aws/request.Request" representing the
  1374. // client's request for the GetLoggingOptions operation. The "output" return
  1375. // value can be used to capture response data after the request's "Send" method
  1376. // is called.
  1377. //
  1378. // Creating a request object using this method should be used when you want to inject
  1379. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1380. // access properties on the request object before or after sending the request. If
  1381. // you just want the service response, call the GetLoggingOptions method directly
  1382. // instead.
  1383. //
  1384. // Note: You must call the "Send" method on the returned request object in order
  1385. // to execute the request.
  1386. //
  1387. // // Example sending a request using the GetLoggingOptionsRequest method.
  1388. // req, resp := client.GetLoggingOptionsRequest(params)
  1389. //
  1390. // err := req.Send()
  1391. // if err == nil { // resp is now filled
  1392. // fmt.Println(resp)
  1393. // }
  1394. //
  1395. func (c *IoT) GetLoggingOptionsRequest(input *GetLoggingOptionsInput) (req *request.Request, output *GetLoggingOptionsOutput) {
  1396. op := &request.Operation{
  1397. Name: opGetLoggingOptions,
  1398. HTTPMethod: "GET",
  1399. HTTPPath: "/loggingOptions",
  1400. }
  1401. if input == nil {
  1402. input = &GetLoggingOptionsInput{}
  1403. }
  1404. req = c.newRequest(op, input, output)
  1405. output = &GetLoggingOptionsOutput{}
  1406. req.Data = output
  1407. return
  1408. }
  1409. // Gets the logging options.
  1410. func (c *IoT) GetLoggingOptions(input *GetLoggingOptionsInput) (*GetLoggingOptionsOutput, error) {
  1411. req, out := c.GetLoggingOptionsRequest(input)
  1412. err := req.Send()
  1413. return out, err
  1414. }
  1415. const opGetPolicy = "GetPolicy"
  1416. // GetPolicyRequest generates a "aws/request.Request" representing the
  1417. // client's request for the GetPolicy operation. The "output" return
  1418. // value can be used to capture response data after the request's "Send" method
  1419. // is called.
  1420. //
  1421. // Creating a request object using this method should be used when you want to inject
  1422. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1423. // access properties on the request object before or after sending the request. If
  1424. // you just want the service response, call the GetPolicy method directly
  1425. // instead.
  1426. //
  1427. // Note: You must call the "Send" method on the returned request object in order
  1428. // to execute the request.
  1429. //
  1430. // // Example sending a request using the GetPolicyRequest method.
  1431. // req, resp := client.GetPolicyRequest(params)
  1432. //
  1433. // err := req.Send()
  1434. // if err == nil { // resp is now filled
  1435. // fmt.Println(resp)
  1436. // }
  1437. //
  1438. func (c *IoT) GetPolicyRequest(input *GetPolicyInput) (req *request.Request, output *GetPolicyOutput) {
  1439. op := &request.Operation{
  1440. Name: opGetPolicy,
  1441. HTTPMethod: "GET",
  1442. HTTPPath: "/policies/{policyName}",
  1443. }
  1444. if input == nil {
  1445. input = &GetPolicyInput{}
  1446. }
  1447. req = c.newRequest(op, input, output)
  1448. output = &GetPolicyOutput{}
  1449. req.Data = output
  1450. return
  1451. }
  1452. // Gets information about the specified policy with the policy document of the
  1453. // default version.
  1454. func (c *IoT) GetPolicy(input *GetPolicyInput) (*GetPolicyOutput, error) {
  1455. req, out := c.GetPolicyRequest(input)
  1456. err := req.Send()
  1457. return out, err
  1458. }
  1459. const opGetPolicyVersion = "GetPolicyVersion"
  1460. // GetPolicyVersionRequest generates a "aws/request.Request" representing the
  1461. // client's request for the GetPolicyVersion operation. The "output" return
  1462. // value can be used to capture response data after the request's "Send" method
  1463. // is called.
  1464. //
  1465. // Creating a request object using this method should be used when you want to inject
  1466. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1467. // access properties on the request object before or after sending the request. If
  1468. // you just want the service response, call the GetPolicyVersion method directly
  1469. // instead.
  1470. //
  1471. // Note: You must call the "Send" method on the returned request object in order
  1472. // to execute the request.
  1473. //
  1474. // // Example sending a request using the GetPolicyVersionRequest method.
  1475. // req, resp := client.GetPolicyVersionRequest(params)
  1476. //
  1477. // err := req.Send()
  1478. // if err == nil { // resp is now filled
  1479. // fmt.Println(resp)
  1480. // }
  1481. //
  1482. func (c *IoT) GetPolicyVersionRequest(input *GetPolicyVersionInput) (req *request.Request, output *GetPolicyVersionOutput) {
  1483. op := &request.Operation{
  1484. Name: opGetPolicyVersion,
  1485. HTTPMethod: "GET",
  1486. HTTPPath: "/policies/{policyName}/version/{policyVersionId}",
  1487. }
  1488. if input == nil {
  1489. input = &GetPolicyVersionInput{}
  1490. }
  1491. req = c.newRequest(op, input, output)
  1492. output = &GetPolicyVersionOutput{}
  1493. req.Data = output
  1494. return
  1495. }
  1496. // Gets information about the specified policy version.
  1497. func (c *IoT) GetPolicyVersion(input *GetPolicyVersionInput) (*GetPolicyVersionOutput, error) {
  1498. req, out := c.GetPolicyVersionRequest(input)
  1499. err := req.Send()
  1500. return out, err
  1501. }
  1502. const opGetRegistrationCode = "GetRegistrationCode"
  1503. // GetRegistrationCodeRequest generates a "aws/request.Request" representing the
  1504. // client's request for the GetRegistrationCode operation. The "output" return
  1505. // value can be used to capture response data after the request's "Send" method
  1506. // is called.
  1507. //
  1508. // Creating a request object using this method should be used when you want to inject
  1509. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1510. // access properties on the request object before or after sending the request. If
  1511. // you just want the service response, call the GetRegistrationCode method directly
  1512. // instead.
  1513. //
  1514. // Note: You must call the "Send" method on the returned request object in order
  1515. // to execute the request.
  1516. //
  1517. // // Example sending a request using the GetRegistrationCodeRequest method.
  1518. // req, resp := client.GetRegistrationCodeRequest(params)
  1519. //
  1520. // err := req.Send()
  1521. // if err == nil { // resp is now filled
  1522. // fmt.Println(resp)
  1523. // }
  1524. //
  1525. func (c *IoT) GetRegistrationCodeRequest(input *GetRegistrationCodeInput) (req *request.Request, output *GetRegistrationCodeOutput) {
  1526. op := &request.Operation{
  1527. Name: opGetRegistrationCode,
  1528. HTTPMethod: "GET",
  1529. HTTPPath: "/registrationcode",
  1530. }
  1531. if input == nil {
  1532. input = &GetRegistrationCodeInput{}
  1533. }
  1534. req = c.newRequest(op, input, output)
  1535. output = &GetRegistrationCodeOutput{}
  1536. req.Data = output
  1537. return
  1538. }
  1539. // Gets a registration code used to register a CA certificate with AWS IoT.
  1540. func (c *IoT) GetRegistrationCode(input *GetRegistrationCodeInput) (*GetRegistrationCodeOutput, error) {
  1541. req, out := c.GetRegistrationCodeRequest(input)
  1542. err := req.Send()
  1543. return out, err
  1544. }
  1545. const opGetTopicRule = "GetTopicRule"
  1546. // GetTopicRuleRequest generates a "aws/request.Request" representing the
  1547. // client's request for the GetTopicRule operation. The "output" return
  1548. // value can be used to capture response data after the request's "Send" method
  1549. // is called.
  1550. //
  1551. // Creating a request object using this method should be used when you want to inject
  1552. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1553. // access properties on the request object before or after sending the request. If
  1554. // you just want the service response, call the GetTopicRule method directly
  1555. // instead.
  1556. //
  1557. // Note: You must call the "Send" method on the returned request object in order
  1558. // to execute the request.
  1559. //
  1560. // // Example sending a request using the GetTopicRuleRequest method.
  1561. // req, resp := client.GetTopicRuleRequest(params)
  1562. //
  1563. // err := req.Send()
  1564. // if err == nil { // resp is now filled
  1565. // fmt.Println(resp)
  1566. // }
  1567. //
  1568. func (c *IoT) GetTopicRuleRequest(input *GetTopicRuleInput) (req *request.Request, output *GetTopicRuleOutput) {
  1569. op := &request.Operation{
  1570. Name: opGetTopicRule,
  1571. HTTPMethod: "GET",
  1572. HTTPPath: "/rules/{ruleName}",
  1573. }
  1574. if input == nil {
  1575. input = &GetTopicRuleInput{}
  1576. }
  1577. req = c.newRequest(op, input, output)
  1578. output = &GetTopicRuleOutput{}
  1579. req.Data = output
  1580. return
  1581. }
  1582. // Gets information about the specified rule.
  1583. func (c *IoT) GetTopicRule(input *GetTopicRuleInput) (*GetTopicRuleOutput, error) {
  1584. req, out := c.GetTopicRuleRequest(input)
  1585. err := req.Send()
  1586. return out, err
  1587. }
  1588. const opListCACertificates = "ListCACertificates"
  1589. // ListCACertificatesRequest generates a "aws/request.Request" representing the
  1590. // client's request for the ListCACertificates operation. The "output" return
  1591. // value can be used to capture response data after the request's "Send" method
  1592. // is called.
  1593. //
  1594. // Creating a request object using this method should be used when you want to inject
  1595. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1596. // access properties on the request object before or after sending the request. If
  1597. // you just want the service response, call the ListCACertificates method directly
  1598. // instead.
  1599. //
  1600. // Note: You must call the "Send" method on the returned request object in order
  1601. // to execute the request.
  1602. //
  1603. // // Example sending a request using the ListCACertificatesRequest method.
  1604. // req, resp := client.ListCACertificatesRequest(params)
  1605. //
  1606. // err := req.Send()
  1607. // if err == nil { // resp is now filled
  1608. // fmt.Println(resp)
  1609. // }
  1610. //
  1611. func (c *IoT) ListCACertificatesRequest(input *ListCACertificatesInput) (req *request.Request, output *ListCACertificatesOutput) {
  1612. op := &request.Operation{
  1613. Name: opListCACertificates,
  1614. HTTPMethod: "GET",
  1615. HTTPPath: "/cacertificates",
  1616. }
  1617. if input == nil {
  1618. input = &ListCACertificatesInput{}
  1619. }
  1620. req = c.newRequest(op, input, output)
  1621. output = &ListCACertificatesOutput{}
  1622. req.Data = output
  1623. return
  1624. }
  1625. // Lists the CA certificates registered for your AWS account.
  1626. //
  1627. // The results are paginated with a default page size of 25. You can use the
  1628. // returned marker to retrieve additional results.
  1629. func (c *IoT) ListCACertificates(input *ListCACertificatesInput) (*ListCACertificatesOutput, error) {
  1630. req, out := c.ListCACertificatesRequest(input)
  1631. err := req.Send()
  1632. return out, err
  1633. }
  1634. const opListCertificates = "ListCertificates"
  1635. // ListCertificatesRequest generates a "aws/request.Request" representing the
  1636. // client's request for the ListCertificates operation. The "output" return
  1637. // value can be used to capture response data after the request's "Send" method
  1638. // is called.
  1639. //
  1640. // Creating a request object using this method should be used when you want to inject
  1641. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1642. // access properties on the request object before or after sending the request. If
  1643. // you just want the service response, call the ListCertificates method directly
  1644. // instead.
  1645. //
  1646. // Note: You must call the "Send" method on the returned request object in order
  1647. // to execute the request.
  1648. //
  1649. // // Example sending a request using the ListCertificatesRequest method.
  1650. // req, resp := client.ListCertificatesRequest(params)
  1651. //
  1652. // err := req.Send()
  1653. // if err == nil { // resp is now filled
  1654. // fmt.Println(resp)
  1655. // }
  1656. //
  1657. func (c *IoT) ListCertificatesRequest(input *ListCertificatesInput) (req *request.Request, output *ListCertificatesOutput) {
  1658. op := &request.Operation{
  1659. Name: opListCertificates,
  1660. HTTPMethod: "GET",
  1661. HTTPPath: "/certificates",
  1662. }
  1663. if input == nil {
  1664. input = &ListCertificatesInput{}
  1665. }
  1666. req = c.newRequest(op, input, output)
  1667. output = &ListCertificatesOutput{}
  1668. req.Data = output
  1669. return
  1670. }
  1671. // Lists the certificates registered in your AWS account.
  1672. //
  1673. // The results are paginated with a default page size of 25. You can use the
  1674. // returned marker to retrieve additional results.
  1675. func (c *IoT) ListCertificates(input *ListCertificatesInput) (*ListCertificatesOutput, error) {
  1676. req, out := c.ListCertificatesRequest(input)
  1677. err := req.Send()
  1678. return out, err
  1679. }
  1680. const opListCertificatesByCA = "ListCertificatesByCA"
  1681. // ListCertificatesByCARequest generates a "aws/request.Request" representing the
  1682. // client's request for the ListCertificatesByCA operation. The "output" return
  1683. // value can be used to capture response data after the request's "Send" method
  1684. // is called.
  1685. //
  1686. // Creating a request object using this method should be used when you want to inject
  1687. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1688. // access properties on the request object before or after sending the request. If
  1689. // you just want the service response, call the ListCertificatesByCA method directly
  1690. // instead.
  1691. //
  1692. // Note: You must call the "Send" method on the returned request object in order
  1693. // to execute the request.
  1694. //
  1695. // // Example sending a request using the ListCertificatesByCARequest method.
  1696. // req, resp := client.ListCertificatesByCARequest(params)
  1697. //
  1698. // err := req.Send()
  1699. // if err == nil { // resp is now filled
  1700. // fmt.Println(resp)
  1701. // }
  1702. //
  1703. func (c *IoT) ListCertificatesByCARequest(input *ListCertificatesByCAInput) (req *request.Request, output *ListCertificatesByCAOutput) {
  1704. op := &request.Operation{
  1705. Name: opListCertificatesByCA,
  1706. HTTPMethod: "GET",
  1707. HTTPPath: "/certificates-by-ca/{caCertificateId}",
  1708. }
  1709. if input == nil {
  1710. input = &ListCertificatesByCAInput{}
  1711. }
  1712. req = c.newRequest(op, input, output)
  1713. output = &ListCertificatesByCAOutput{}
  1714. req.Data = output
  1715. return
  1716. }
  1717. // List the device certificates signed by the specified CA certificate.
  1718. func (c *IoT) ListCertificatesByCA(input *ListCertificatesByCAInput) (*ListCertificatesByCAOutput, error) {
  1719. req, out := c.ListCertificatesByCARequest(input)
  1720. err := req.Send()
  1721. return out, err
  1722. }
  1723. const opListOutgoingCertificates = "ListOutgoingCertificates"
  1724. // ListOutgoingCertificatesRequest generates a "aws/request.Request" representing the
  1725. // client's request for the ListOutgoingCertificates operation. The "output" return
  1726. // value can be used to capture response data after the request's "Send" method
  1727. // is called.
  1728. //
  1729. // Creating a request object using this method should be used when you want to inject
  1730. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1731. // access properties on the request object before or after sending the request. If
  1732. // you just want the service response, call the ListOutgoingCertificates method directly
  1733. // instead.
  1734. //
  1735. // Note: You must call the "Send" method on the returned request object in order
  1736. // to execute the request.
  1737. //
  1738. // // Example sending a request using the ListOutgoingCertificatesRequest method.
  1739. // req, resp := client.ListOutgoingCertificatesRequest(params)
  1740. //
  1741. // err := req.Send()
  1742. // if err == nil { // resp is now filled
  1743. // fmt.Println(resp)
  1744. // }
  1745. //
  1746. func (c *IoT) ListOutgoingCertificatesRequest(input *ListOutgoingCertificatesInput) (req *request.Request, output *ListOutgoingCertificatesOutput) {
  1747. op := &request.Operation{
  1748. Name: opListOutgoingCertificates,
  1749. HTTPMethod: "GET",
  1750. HTTPPath: "/certificates-out-going",
  1751. }
  1752. if input == nil {
  1753. input = &ListOutgoingCertificatesInput{}
  1754. }
  1755. req = c.newRequest(op, input, output)
  1756. output = &ListOutgoingCertificatesOutput{}
  1757. req.Data = output
  1758. return
  1759. }
  1760. // Lists certificates that are being transfered but not yet accepted.
  1761. func (c *IoT) ListOutgoingCertificates(input *ListOutgoingCertificatesInput) (*ListOutgoingCertificatesOutput, error) {
  1762. req, out := c.ListOutgoingCertificatesRequest(input)
  1763. err := req.Send()
  1764. return out, err
  1765. }
  1766. const opListPolicies = "ListPolicies"
  1767. // ListPoliciesRequest generates a "aws/request.Request" representing the
  1768. // client's request for the ListPolicies operation. The "output" return
  1769. // value can be used to capture response data after the request's "Send" method
  1770. // is called.
  1771. //
  1772. // Creating a request object using this method should be used when you want to inject
  1773. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1774. // access properties on the request object before or after sending the request. If
  1775. // you just want the service response, call the ListPolicies method directly
  1776. // instead.
  1777. //
  1778. // Note: You must call the "Send" method on the returned request object in order
  1779. // to execute the request.
  1780. //
  1781. // // Example sending a request using the ListPoliciesRequest method.
  1782. // req, resp := client.ListPoliciesRequest(params)
  1783. //
  1784. // err := req.Send()
  1785. // if err == nil { // resp is now filled
  1786. // fmt.Println(resp)
  1787. // }
  1788. //
  1789. func (c *IoT) ListPoliciesRequest(input *ListPoliciesInput) (req *request.Request, output *ListPoliciesOutput) {
  1790. op := &request.Operation{
  1791. Name: opListPolicies,
  1792. HTTPMethod: "GET",
  1793. HTTPPath: "/policies",
  1794. }
  1795. if input == nil {
  1796. input = &ListPoliciesInput{}
  1797. }
  1798. req = c.newRequest(op, input, output)
  1799. output = &ListPoliciesOutput{}
  1800. req.Data = output
  1801. return
  1802. }
  1803. // Lists your policies.
  1804. func (c *IoT) ListPolicies(input *ListPoliciesInput) (*ListPoliciesOutput, error) {
  1805. req, out := c.ListPoliciesRequest(input)
  1806. err := req.Send()
  1807. return out, err
  1808. }
  1809. const opListPolicyPrincipals = "ListPolicyPrincipals"
  1810. // ListPolicyPrincipalsRequest generates a "aws/request.Request" representing the
  1811. // client's request for the ListPolicyPrincipals operation. The "output" return
  1812. // value can be used to capture response data after the request's "Send" method
  1813. // is called.
  1814. //
  1815. // Creating a request object using this method should be used when you want to inject
  1816. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1817. // access properties on the request object before or after sending the request. If
  1818. // you just want the service response, call the ListPolicyPrincipals method directly
  1819. // instead.
  1820. //
  1821. // Note: You must call the "Send" method on the returned request object in order
  1822. // to execute the request.
  1823. //
  1824. // // Example sending a request using the ListPolicyPrincipalsRequest method.
  1825. // req, resp := client.ListPolicyPrincipalsRequest(params)
  1826. //
  1827. // err := req.Send()
  1828. // if err == nil { // resp is now filled
  1829. // fmt.Println(resp)
  1830. // }
  1831. //
  1832. func (c *IoT) ListPolicyPrincipalsRequest(input *ListPolicyPrincipalsInput) (req *request.Request, output *ListPolicyPrincipalsOutput) {
  1833. op := &request.Operation{
  1834. Name: opListPolicyPrincipals,
  1835. HTTPMethod: "GET",
  1836. HTTPPath: "/policy-principals",
  1837. }
  1838. if input == nil {
  1839. input = &ListPolicyPrincipalsInput{}
  1840. }
  1841. req = c.newRequest(op, input, output)
  1842. output = &ListPolicyPrincipalsOutput{}
  1843. req.Data = output
  1844. return
  1845. }
  1846. // Lists the principals associated with the specified policy.
  1847. func (c *IoT) ListPolicyPrincipals(input *ListPolicyPrincipalsInput) (*ListPolicyPrincipalsOutput, error) {
  1848. req, out := c.ListPolicyPrincipalsRequest(input)
  1849. err := req.Send()
  1850. return out, err
  1851. }
  1852. const opListPolicyVersions = "ListPolicyVersions"
  1853. // ListPolicyVersionsRequest generates a "aws/request.Request" representing the
  1854. // client's request for the ListPolicyVersions operation. The "output" return
  1855. // value can be used to capture response data after the request's "Send" method
  1856. // is called.
  1857. //
  1858. // Creating a request object using this method should be used when you want to inject
  1859. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1860. // access properties on the request object before or after sending the request. If
  1861. // you just want the service response, call the ListPolicyVersions method directly
  1862. // instead.
  1863. //
  1864. // Note: You must call the "Send" method on the returned request object in order
  1865. // to execute the request.
  1866. //
  1867. // // Example sending a request using the ListPolicyVersionsRequest method.
  1868. // req, resp := client.ListPolicyVersionsRequest(params)
  1869. //
  1870. // err := req.Send()
  1871. // if err == nil { // resp is now filled
  1872. // fmt.Println(resp)
  1873. // }
  1874. //
  1875. func (c *IoT) ListPolicyVersionsRequest(input *ListPolicyVersionsInput) (req *request.Request, output *ListPolicyVersionsOutput) {
  1876. op := &request.Operation{
  1877. Name: opListPolicyVersions,
  1878. HTTPMethod: "GET",
  1879. HTTPPath: "/policies/{policyName}/version",
  1880. }
  1881. if input == nil {
  1882. input = &ListPolicyVersionsInput{}
  1883. }
  1884. req = c.newRequest(op, input, output)
  1885. output = &ListPolicyVersionsOutput{}
  1886. req.Data = output
  1887. return
  1888. }
  1889. // Lists the versions of the specified policy and identifies the default version.
  1890. func (c *IoT) ListPolicyVersions(input *ListPolicyVersionsInput) (*ListPolicyVersionsOutput, error) {
  1891. req, out := c.ListPolicyVersionsRequest(input)
  1892. err := req.Send()
  1893. return out, err
  1894. }
  1895. const opListPrincipalPolicies = "ListPrincipalPolicies"
  1896. // ListPrincipalPoliciesRequest generates a "aws/request.Request" representing the
  1897. // client's request for the ListPrincipalPolicies operation. The "output" return
  1898. // value can be used to capture response data after the request's "Send" method
  1899. // is called.
  1900. //
  1901. // Creating a request object using this method should be used when you want to inject
  1902. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1903. // access properties on the request object before or after sending the request. If
  1904. // you just want the service response, call the ListPrincipalPolicies method directly
  1905. // instead.
  1906. //
  1907. // Note: You must call the "Send" method on the returned request object in order
  1908. // to execute the request.
  1909. //
  1910. // // Example sending a request using the ListPrincipalPoliciesRequest method.
  1911. // req, resp := client.ListPrincipalPoliciesRequest(params)
  1912. //
  1913. // err := req.Send()
  1914. // if err == nil { // resp is now filled
  1915. // fmt.Println(resp)
  1916. // }
  1917. //
  1918. func (c *IoT) ListPrincipalPoliciesRequest(input *ListPrincipalPoliciesInput) (req *request.Request, output *ListPrincipalPoliciesOutput) {
  1919. op := &request.Operation{
  1920. Name: opListPrincipalPolicies,
  1921. HTTPMethod: "GET",
  1922. HTTPPath: "/principal-policies",
  1923. }
  1924. if input == nil {
  1925. input = &ListPrincipalPoliciesInput{}
  1926. }
  1927. req = c.newRequest(op, input, output)
  1928. output = &ListPrincipalPoliciesOutput{}
  1929. req.Data = output
  1930. return
  1931. }
  1932. // Lists the policies attached to the specified principal. If you use an Cognito
  1933. // identity, the ID must be in AmazonCognito Identity format (http://docs.aws.amazon.com/cognitoidentity/latest/APIReference/API_GetCredentialsForIdentity.html#API_GetCredentialsForIdentity_RequestSyntax).
  1934. func (c *IoT) ListPrincipalPolicies(input *ListPrincipalPoliciesInput) (*ListPrincipalPoliciesOutput, error) {
  1935. req, out := c.ListPrincipalPoliciesRequest(input)
  1936. err := req.Send()
  1937. return out, err
  1938. }
  1939. const opListPrincipalThings = "ListPrincipalThings"
  1940. // ListPrincipalThingsRequest generates a "aws/request.Request" representing the
  1941. // client's request for the ListPrincipalThings operation. The "output" return
  1942. // value can be used to capture response data after the request's "Send" method
  1943. // is called.
  1944. //
  1945. // Creating a request object using this method should be used when you want to inject
  1946. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1947. // access properties on the request object before or after sending the request. If
  1948. // you just want the service response, call the ListPrincipalThings method directly
  1949. // instead.
  1950. //
  1951. // Note: You must call the "Send" method on the returned request object in order
  1952. // to execute the request.
  1953. //
  1954. // // Example sending a request using the ListPrincipalThingsRequest method.
  1955. // req, resp := client.ListPrincipalThingsRequest(params)
  1956. //
  1957. // err := req.Send()
  1958. // if err == nil { // resp is now filled
  1959. // fmt.Println(resp)
  1960. // }
  1961. //
  1962. func (c *IoT) ListPrincipalThingsRequest(input *ListPrincipalThingsInput) (req *request.Request, output *ListPrincipalThingsOutput) {
  1963. op := &request.Operation{
  1964. Name: opListPrincipalThings,
  1965. HTTPMethod: "GET",
  1966. HTTPPath: "/principals/things",
  1967. }
  1968. if input == nil {
  1969. input = &ListPrincipalThingsInput{}
  1970. }
  1971. req = c.newRequest(op, input, output)
  1972. output = &ListPrincipalThingsOutput{}
  1973. req.Data = output
  1974. return
  1975. }
  1976. // Lists the things associated with the specified principal.
  1977. func (c *IoT) ListPrincipalThings(input *ListPrincipalThingsInput) (*ListPrincipalThingsOutput, error) {
  1978. req, out := c.ListPrincipalThingsRequest(input)
  1979. err := req.Send()
  1980. return out, err
  1981. }
  1982. const opListThingPrincipals = "ListThingPrincipals"
  1983. // ListThingPrincipalsRequest generates a "aws/request.Request" representing the
  1984. // client's request for the ListThingPrincipals operation. The "output" return
  1985. // value can be used to capture response data after the request's "Send" method
  1986. // is called.
  1987. //
  1988. // Creating a request object using this method should be used when you want to inject
  1989. // custom logic into the request's lifecycle using a custom handler, or if you want to
  1990. // access properties on the request object before or after sending the request. If
  1991. // you just want the service response, call the ListThingPrincipals method directly
  1992. // instead.
  1993. //
  1994. // Note: You must call the "Send" method on the returned request object in order
  1995. // to execute the request.
  1996. //
  1997. // // Example sending a request using the ListThingPrincipalsRequest method.
  1998. // req, resp := client.ListThingPrincipalsRequest(params)
  1999. //
  2000. // err := req.Send()
  2001. // if err == nil { // resp is now filled
  2002. // fmt.Println(resp)
  2003. // }
  2004. //
  2005. func (c *IoT) ListThingPrincipalsRequest(input *ListThingPrincipalsInput) (req *request.Request, output *ListThingPrincipalsOutput) {
  2006. op := &request.Operation{
  2007. Name: opListThingPrincipals,
  2008. HTTPMethod: "GET",
  2009. HTTPPath: "/things/{thingName}/principals",
  2010. }
  2011. if input == nil {
  2012. input = &ListThingPrincipalsInput{}
  2013. }
  2014. req = c.newRequest(op, input, output)
  2015. output = &ListThingPrincipalsOutput{}
  2016. req.Data = output
  2017. return
  2018. }
  2019. // Lists the principals associated with the specified thing.
  2020. func (c *IoT) ListThingPrincipals(input *ListThingPrincipalsInput) (*ListThingPrincipalsOutput, error) {
  2021. req, out := c.ListThingPrincipalsRequest(input)
  2022. err := req.Send()
  2023. return out, err
  2024. }
  2025. const opListThingTypes = "ListThingTypes"
  2026. // ListThingTypesRequest generates a "aws/request.Request" representing the
  2027. // client's request for the ListThingTypes operation. The "output" return
  2028. // value can be used to capture response data after the request's "Send" method
  2029. // is called.
  2030. //
  2031. // Creating a request object using this method should be used when you want to inject
  2032. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2033. // access properties on the request object before or after sending the request. If
  2034. // you just want the service response, call the ListThingTypes method directly
  2035. // instead.
  2036. //
  2037. // Note: You must call the "Send" method on the returned request object in order
  2038. // to execute the request.
  2039. //
  2040. // // Example sending a request using the ListThingTypesRequest method.
  2041. // req, resp := client.ListThingTypesRequest(params)
  2042. //
  2043. // err := req.Send()
  2044. // if err == nil { // resp is now filled
  2045. // fmt.Println(resp)
  2046. // }
  2047. //
  2048. func (c *IoT) ListThingTypesRequest(input *ListThingTypesInput) (req *request.Request, output *ListThingTypesOutput) {
  2049. op := &request.Operation{
  2050. Name: opListThingTypes,
  2051. HTTPMethod: "GET",
  2052. HTTPPath: "/thing-types",
  2053. }
  2054. if input == nil {
  2055. input = &ListThingTypesInput{}
  2056. }
  2057. req = c.newRequest(op, input, output)
  2058. output = &ListThingTypesOutput{}
  2059. req.Data = output
  2060. return
  2061. }
  2062. // Lists the existing thing types.
  2063. func (c *IoT) ListThingTypes(input *ListThingTypesInput) (*ListThingTypesOutput, error) {
  2064. req, out := c.ListThingTypesRequest(input)
  2065. err := req.Send()
  2066. return out, err
  2067. }
  2068. const opListThings = "ListThings"
  2069. // ListThingsRequest generates a "aws/request.Request" representing the
  2070. // client's request for the ListThings operation. The "output" return
  2071. // value can be used to capture response data after the request's "Send" method
  2072. // is called.
  2073. //
  2074. // Creating a request object using this method should be used when you want to inject
  2075. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2076. // access properties on the request object before or after sending the request. If
  2077. // you just want the service response, call the ListThings method directly
  2078. // instead.
  2079. //
  2080. // Note: You must call the "Send" method on the returned request object in order
  2081. // to execute the request.
  2082. //
  2083. // // Example sending a request using the ListThingsRequest method.
  2084. // req, resp := client.ListThingsRequest(params)
  2085. //
  2086. // err := req.Send()
  2087. // if err == nil { // resp is now filled
  2088. // fmt.Println(resp)
  2089. // }
  2090. //
  2091. func (c *IoT) ListThingsRequest(input *ListThingsInput) (req *request.Request, output *ListThingsOutput) {
  2092. op := &request.Operation{
  2093. Name: opListThings,
  2094. HTTPMethod: "GET",
  2095. HTTPPath: "/things",
  2096. }
  2097. if input == nil {
  2098. input = &ListThingsInput{}
  2099. }
  2100. req = c.newRequest(op, input, output)
  2101. output = &ListThingsOutput{}
  2102. req.Data = output
  2103. return
  2104. }
  2105. // Lists your things. Use the attributeName and attributeValue parameters to
  2106. // filter your things. For example, calling ListThings with attributeName=Color
  2107. // and attributeValue=Red retrieves all things in the registry that contain
  2108. // an attribute Color with the value Red.
  2109. func (c *IoT) ListThings(input *ListThingsInput) (*ListThingsOutput, error) {
  2110. req, out := c.ListThingsRequest(input)
  2111. err := req.Send()
  2112. return out, err
  2113. }
  2114. const opListTopicRules = "ListTopicRules"
  2115. // ListTopicRulesRequest generates a "aws/request.Request" representing the
  2116. // client's request for the ListTopicRules operation. The "output" return
  2117. // value can be used to capture response data after the request's "Send" method
  2118. // is called.
  2119. //
  2120. // Creating a request object using this method should be used when you want to inject
  2121. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2122. // access properties on the request object before or after sending the request. If
  2123. // you just want the service response, call the ListTopicRules method directly
  2124. // instead.
  2125. //
  2126. // Note: You must call the "Send" method on the returned request object in order
  2127. // to execute the request.
  2128. //
  2129. // // Example sending a request using the ListTopicRulesRequest method.
  2130. // req, resp := client.ListTopicRulesRequest(params)
  2131. //
  2132. // err := req.Send()
  2133. // if err == nil { // resp is now filled
  2134. // fmt.Println(resp)
  2135. // }
  2136. //
  2137. func (c *IoT) ListTopicRulesRequest(input *ListTopicRulesInput) (req *request.Request, output *ListTopicRulesOutput) {
  2138. op := &request.Operation{
  2139. Name: opListTopicRules,
  2140. HTTPMethod: "GET",
  2141. HTTPPath: "/rules",
  2142. }
  2143. if input == nil {
  2144. input = &ListTopicRulesInput{}
  2145. }
  2146. req = c.newRequest(op, input, output)
  2147. output = &ListTopicRulesOutput{}
  2148. req.Data = output
  2149. return
  2150. }
  2151. // Lists the rules for the specific topic.
  2152. func (c *IoT) ListTopicRules(input *ListTopicRulesInput) (*ListTopicRulesOutput, error) {
  2153. req, out := c.ListTopicRulesRequest(input)
  2154. err := req.Send()
  2155. return out, err
  2156. }
  2157. const opRegisterCACertificate = "RegisterCACertificate"
  2158. // RegisterCACertificateRequest generates a "aws/request.Request" representing the
  2159. // client's request for the RegisterCACertificate operation. The "output" return
  2160. // value can be used to capture response data after the request's "Send" method
  2161. // is called.
  2162. //
  2163. // Creating a request object using this method should be used when you want to inject
  2164. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2165. // access properties on the request object before or after sending the request. If
  2166. // you just want the service response, call the RegisterCACertificate method directly
  2167. // instead.
  2168. //
  2169. // Note: You must call the "Send" method on the returned request object in order
  2170. // to execute the request.
  2171. //
  2172. // // Example sending a request using the RegisterCACertificateRequest method.
  2173. // req, resp := client.RegisterCACertificateRequest(params)
  2174. //
  2175. // err := req.Send()
  2176. // if err == nil { // resp is now filled
  2177. // fmt.Println(resp)
  2178. // }
  2179. //
  2180. func (c *IoT) RegisterCACertificateRequest(input *RegisterCACertificateInput) (req *request.Request, output *RegisterCACertificateOutput) {
  2181. op := &request.Operation{
  2182. Name: opRegisterCACertificate,
  2183. HTTPMethod: "POST",
  2184. HTTPPath: "/cacertificate",
  2185. }
  2186. if input == nil {
  2187. input = &RegisterCACertificateInput{}
  2188. }
  2189. req = c.newRequest(op, input, output)
  2190. output = &RegisterCACertificateOutput{}
  2191. req.Data = output
  2192. return
  2193. }
  2194. // Registers a CA certificate with AWS IoT. This CA certificate can then be
  2195. // used to sign device certificates, which can be then registered with AWS IoT.
  2196. // You can register up to 10 CA certificates per AWS account that have the same
  2197. // subject field and public key. This enables you to have up to 10 certificate
  2198. // authorities sign your device certificates. If you have more than one CA certificate
  2199. // registered, make sure you pass the CA certificate when you register your
  2200. // device certificates with the RegisterCertificate API.
  2201. func (c *IoT) RegisterCACertificate(input *RegisterCACertificateInput) (*RegisterCACertificateOutput, error) {
  2202. req, out := c.RegisterCACertificateRequest(input)
  2203. err := req.Send()
  2204. return out, err
  2205. }
  2206. const opRegisterCertificate = "RegisterCertificate"
  2207. // RegisterCertificateRequest generates a "aws/request.Request" representing the
  2208. // client's request for the RegisterCertificate operation. The "output" return
  2209. // value can be used to capture response data after the request's "Send" method
  2210. // is called.
  2211. //
  2212. // Creating a request object using this method should be used when you want to inject
  2213. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2214. // access properties on the request object before or after sending the request. If
  2215. // you just want the service response, call the RegisterCertificate method directly
  2216. // instead.
  2217. //
  2218. // Note: You must call the "Send" method on the returned request object in order
  2219. // to execute the request.
  2220. //
  2221. // // Example sending a request using the RegisterCertificateRequest method.
  2222. // req, resp := client.RegisterCertificateRequest(params)
  2223. //
  2224. // err := req.Send()
  2225. // if err == nil { // resp is now filled
  2226. // fmt.Println(resp)
  2227. // }
  2228. //
  2229. func (c *IoT) RegisterCertificateRequest(input *RegisterCertificateInput) (req *request.Request, output *RegisterCertificateOutput) {
  2230. op := &request.Operation{
  2231. Name: opRegisterCertificate,
  2232. HTTPMethod: "POST",
  2233. HTTPPath: "/certificate/register",
  2234. }
  2235. if input == nil {
  2236. input = &RegisterCertificateInput{}
  2237. }
  2238. req = c.newRequest(op, input, output)
  2239. output = &RegisterCertificateOutput{}
  2240. req.Data = output
  2241. return
  2242. }
  2243. // Registers a device certificate with AWS IoT. If you have more than one CA
  2244. // certificate that has the same subject field, you must specify the CA certificate
  2245. // that was used to sign the device certificate being registered.
  2246. func (c *IoT) RegisterCertificate(input *RegisterCertificateInput) (*RegisterCertificateOutput, error) {
  2247. req, out := c.RegisterCertificateRequest(input)
  2248. err := req.Send()
  2249. return out, err
  2250. }
  2251. const opRejectCertificateTransfer = "RejectCertificateTransfer"
  2252. // RejectCertificateTransferRequest generates a "aws/request.Request" representing the
  2253. // client's request for the RejectCertificateTransfer operation. The "output" return
  2254. // value can be used to capture response data after the request's "Send" method
  2255. // is called.
  2256. //
  2257. // Creating a request object using this method should be used when you want to inject
  2258. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2259. // access properties on the request object before or after sending the request. If
  2260. // you just want the service response, call the RejectCertificateTransfer method directly
  2261. // instead.
  2262. //
  2263. // Note: You must call the "Send" method on the returned request object in order
  2264. // to execute the request.
  2265. //
  2266. // // Example sending a request using the RejectCertificateTransferRequest method.
  2267. // req, resp := client.RejectCertificateTransferRequest(params)
  2268. //
  2269. // err := req.Send()
  2270. // if err == nil { // resp is now filled
  2271. // fmt.Println(resp)
  2272. // }
  2273. //
  2274. func (c *IoT) RejectCertificateTransferRequest(input *RejectCertificateTransferInput) (req *request.Request, output *RejectCertificateTransferOutput) {
  2275. op := &request.Operation{
  2276. Name: opRejectCertificateTransfer,
  2277. HTTPMethod: "PATCH",
  2278. HTTPPath: "/reject-certificate-transfer/{certificateId}",
  2279. }
  2280. if input == nil {
  2281. input = &RejectCertificateTransferInput{}
  2282. }
  2283. req = c.newRequest(op, input, output)
  2284. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  2285. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2286. output = &RejectCertificateTransferOutput{}
  2287. req.Data = output
  2288. return
  2289. }
  2290. // Rejects a pending certificate transfer. After AWS IoT rejects a certificate
  2291. // transfer, the certificate status changes from PENDING_TRANSFER to INACTIVE.
  2292. //
  2293. // To check for pending certificate transfers, call ListCertificates to enumerate
  2294. // your certificates.
  2295. //
  2296. // This operation can only be called by the transfer destination. After it
  2297. // is called, the certificate will be returned to the source's account in the
  2298. // INACTIVE state.
  2299. func (c *IoT) RejectCertificateTransfer(input *RejectCertificateTransferInput) (*RejectCertificateTransferOutput, error) {
  2300. req, out := c.RejectCertificateTransferRequest(input)
  2301. err := req.Send()
  2302. return out, err
  2303. }
  2304. const opReplaceTopicRule = "ReplaceTopicRule"
  2305. // ReplaceTopicRuleRequest generates a "aws/request.Request" representing the
  2306. // client's request for the ReplaceTopicRule operation. The "output" return
  2307. // value can be used to capture response data after the request's "Send" method
  2308. // is called.
  2309. //
  2310. // Creating a request object using this method should be used when you want to inject
  2311. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2312. // access properties on the request object before or after sending the request. If
  2313. // you just want the service response, call the ReplaceTopicRule method directly
  2314. // instead.
  2315. //
  2316. // Note: You must call the "Send" method on the returned request object in order
  2317. // to execute the request.
  2318. //
  2319. // // Example sending a request using the ReplaceTopicRuleRequest method.
  2320. // req, resp := client.ReplaceTopicRuleRequest(params)
  2321. //
  2322. // err := req.Send()
  2323. // if err == nil { // resp is now filled
  2324. // fmt.Println(resp)
  2325. // }
  2326. //
  2327. func (c *IoT) ReplaceTopicRuleRequest(input *ReplaceTopicRuleInput) (req *request.Request, output *ReplaceTopicRuleOutput) {
  2328. op := &request.Operation{
  2329. Name: opReplaceTopicRule,
  2330. HTTPMethod: "PATCH",
  2331. HTTPPath: "/rules/{ruleName}",
  2332. }
  2333. if input == nil {
  2334. input = &ReplaceTopicRuleInput{}
  2335. }
  2336. req = c.newRequest(op, input, output)
  2337. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  2338. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2339. output = &ReplaceTopicRuleOutput{}
  2340. req.Data = output
  2341. return
  2342. }
  2343. // Replaces the specified rule. You must specify all parameters for the new
  2344. // rule. Creating rules is an administrator-level action. Any user who has permission
  2345. // to create rules will be able to access data processed by the rule.
  2346. func (c *IoT) ReplaceTopicRule(input *ReplaceTopicRuleInput) (*ReplaceTopicRuleOutput, error) {
  2347. req, out := c.ReplaceTopicRuleRequest(input)
  2348. err := req.Send()
  2349. return out, err
  2350. }
  2351. const opSetDefaultPolicyVersion = "SetDefaultPolicyVersion"
  2352. // SetDefaultPolicyVersionRequest generates a "aws/request.Request" representing the
  2353. // client's request for the SetDefaultPolicyVersion operation. The "output" return
  2354. // value can be used to capture response data after the request's "Send" method
  2355. // is called.
  2356. //
  2357. // Creating a request object using this method should be used when you want to inject
  2358. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2359. // access properties on the request object before or after sending the request. If
  2360. // you just want the service response, call the SetDefaultPolicyVersion method directly
  2361. // instead.
  2362. //
  2363. // Note: You must call the "Send" method on the returned request object in order
  2364. // to execute the request.
  2365. //
  2366. // // Example sending a request using the SetDefaultPolicyVersionRequest method.
  2367. // req, resp := client.SetDefaultPolicyVersionRequest(params)
  2368. //
  2369. // err := req.Send()
  2370. // if err == nil { // resp is now filled
  2371. // fmt.Println(resp)
  2372. // }
  2373. //
  2374. func (c *IoT) SetDefaultPolicyVersionRequest(input *SetDefaultPolicyVersionInput) (req *request.Request, output *SetDefaultPolicyVersionOutput) {
  2375. op := &request.Operation{
  2376. Name: opSetDefaultPolicyVersion,
  2377. HTTPMethod: "PATCH",
  2378. HTTPPath: "/policies/{policyName}/version/{policyVersionId}",
  2379. }
  2380. if input == nil {
  2381. input = &SetDefaultPolicyVersionInput{}
  2382. }
  2383. req = c.newRequest(op, input, output)
  2384. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  2385. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2386. output = &SetDefaultPolicyVersionOutput{}
  2387. req.Data = output
  2388. return
  2389. }
  2390. // Sets the specified version of the specified policy as the policy's default
  2391. // (operative) version. This action affects all certificates to which the policy
  2392. // is attached. To list the principals the policy is attached to, use the ListPrincipalPolicy
  2393. // API.
  2394. func (c *IoT) SetDefaultPolicyVersion(input *SetDefaultPolicyVersionInput) (*SetDefaultPolicyVersionOutput, error) {
  2395. req, out := c.SetDefaultPolicyVersionRequest(input)
  2396. err := req.Send()
  2397. return out, err
  2398. }
  2399. const opSetLoggingOptions = "SetLoggingOptions"
  2400. // SetLoggingOptionsRequest generates a "aws/request.Request" representing the
  2401. // client's request for the SetLoggingOptions operation. The "output" return
  2402. // value can be used to capture response data after the request's "Send" method
  2403. // is called.
  2404. //
  2405. // Creating a request object using this method should be used when you want to inject
  2406. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2407. // access properties on the request object before or after sending the request. If
  2408. // you just want the service response, call the SetLoggingOptions method directly
  2409. // instead.
  2410. //
  2411. // Note: You must call the "Send" method on the returned request object in order
  2412. // to execute the request.
  2413. //
  2414. // // Example sending a request using the SetLoggingOptionsRequest method.
  2415. // req, resp := client.SetLoggingOptionsRequest(params)
  2416. //
  2417. // err := req.Send()
  2418. // if err == nil { // resp is now filled
  2419. // fmt.Println(resp)
  2420. // }
  2421. //
  2422. func (c *IoT) SetLoggingOptionsRequest(input *SetLoggingOptionsInput) (req *request.Request, output *SetLoggingOptionsOutput) {
  2423. op := &request.Operation{
  2424. Name: opSetLoggingOptions,
  2425. HTTPMethod: "POST",
  2426. HTTPPath: "/loggingOptions",
  2427. }
  2428. if input == nil {
  2429. input = &SetLoggingOptionsInput{}
  2430. }
  2431. req = c.newRequest(op, input, output)
  2432. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  2433. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2434. output = &SetLoggingOptionsOutput{}
  2435. req.Data = output
  2436. return
  2437. }
  2438. // Sets the logging options.
  2439. func (c *IoT) SetLoggingOptions(input *SetLoggingOptionsInput) (*SetLoggingOptionsOutput, error) {
  2440. req, out := c.SetLoggingOptionsRequest(input)
  2441. err := req.Send()
  2442. return out, err
  2443. }
  2444. const opTransferCertificate = "TransferCertificate"
  2445. // TransferCertificateRequest generates a "aws/request.Request" representing the
  2446. // client's request for the TransferCertificate operation. The "output" return
  2447. // value can be used to capture response data after the request's "Send" method
  2448. // is called.
  2449. //
  2450. // Creating a request object using this method should be used when you want to inject
  2451. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2452. // access properties on the request object before or after sending the request. If
  2453. // you just want the service response, call the TransferCertificate method directly
  2454. // instead.
  2455. //
  2456. // Note: You must call the "Send" method on the returned request object in order
  2457. // to execute the request.
  2458. //
  2459. // // Example sending a request using the TransferCertificateRequest method.
  2460. // req, resp := client.TransferCertificateRequest(params)
  2461. //
  2462. // err := req.Send()
  2463. // if err == nil { // resp is now filled
  2464. // fmt.Println(resp)
  2465. // }
  2466. //
  2467. func (c *IoT) TransferCertificateRequest(input *TransferCertificateInput) (req *request.Request, output *TransferCertificateOutput) {
  2468. op := &request.Operation{
  2469. Name: opTransferCertificate,
  2470. HTTPMethod: "PATCH",
  2471. HTTPPath: "/transfer-certificate/{certificateId}",
  2472. }
  2473. if input == nil {
  2474. input = &TransferCertificateInput{}
  2475. }
  2476. req = c.newRequest(op, input, output)
  2477. output = &TransferCertificateOutput{}
  2478. req.Data = output
  2479. return
  2480. }
  2481. // Transfers the specified certificate to the specified AWS account.
  2482. //
  2483. // You can cancel the transfer until it is acknowledged by the recipient.
  2484. //
  2485. // No notification is sent to the transfer destination's account. It is up
  2486. // to the caller to notify the transfer target.
  2487. //
  2488. // The certificate being transferred must not be in the ACTIVE state. You can
  2489. // use the UpdateCertificate API to deactivate it.
  2490. //
  2491. // The certificate must not have any policies attached to it. You can use the
  2492. // DetachPrincipalPolicy API to detach them.
  2493. func (c *IoT) TransferCertificate(input *TransferCertificateInput) (*TransferCertificateOutput, error) {
  2494. req, out := c.TransferCertificateRequest(input)
  2495. err := req.Send()
  2496. return out, err
  2497. }
  2498. const opUpdateCACertificate = "UpdateCACertificate"
  2499. // UpdateCACertificateRequest generates a "aws/request.Request" representing the
  2500. // client's request for the UpdateCACertificate operation. The "output" return
  2501. // value can be used to capture response data after the request's "Send" method
  2502. // is called.
  2503. //
  2504. // Creating a request object using this method should be used when you want to inject
  2505. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2506. // access properties on the request object before or after sending the request. If
  2507. // you just want the service response, call the UpdateCACertificate method directly
  2508. // instead.
  2509. //
  2510. // Note: You must call the "Send" method on the returned request object in order
  2511. // to execute the request.
  2512. //
  2513. // // Example sending a request using the UpdateCACertificateRequest method.
  2514. // req, resp := client.UpdateCACertificateRequest(params)
  2515. //
  2516. // err := req.Send()
  2517. // if err == nil { // resp is now filled
  2518. // fmt.Println(resp)
  2519. // }
  2520. //
  2521. func (c *IoT) UpdateCACertificateRequest(input *UpdateCACertificateInput) (req *request.Request, output *UpdateCACertificateOutput) {
  2522. op := &request.Operation{
  2523. Name: opUpdateCACertificate,
  2524. HTTPMethod: "PUT",
  2525. HTTPPath: "/cacertificate/{caCertificateId}",
  2526. }
  2527. if input == nil {
  2528. input = &UpdateCACertificateInput{}
  2529. }
  2530. req = c.newRequest(op, input, output)
  2531. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  2532. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2533. output = &UpdateCACertificateOutput{}
  2534. req.Data = output
  2535. return
  2536. }
  2537. // Updates a registered CA certificate.
  2538. func (c *IoT) UpdateCACertificate(input *UpdateCACertificateInput) (*UpdateCACertificateOutput, error) {
  2539. req, out := c.UpdateCACertificateRequest(input)
  2540. err := req.Send()
  2541. return out, err
  2542. }
  2543. const opUpdateCertificate = "UpdateCertificate"
  2544. // UpdateCertificateRequest generates a "aws/request.Request" representing the
  2545. // client's request for the UpdateCertificate operation. The "output" return
  2546. // value can be used to capture response data after the request's "Send" method
  2547. // is called.
  2548. //
  2549. // Creating a request object using this method should be used when you want to inject
  2550. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2551. // access properties on the request object before or after sending the request. If
  2552. // you just want the service response, call the UpdateCertificate method directly
  2553. // instead.
  2554. //
  2555. // Note: You must call the "Send" method on the returned request object in order
  2556. // to execute the request.
  2557. //
  2558. // // Example sending a request using the UpdateCertificateRequest method.
  2559. // req, resp := client.UpdateCertificateRequest(params)
  2560. //
  2561. // err := req.Send()
  2562. // if err == nil { // resp is now filled
  2563. // fmt.Println(resp)
  2564. // }
  2565. //
  2566. func (c *IoT) UpdateCertificateRequest(input *UpdateCertificateInput) (req *request.Request, output *UpdateCertificateOutput) {
  2567. op := &request.Operation{
  2568. Name: opUpdateCertificate,
  2569. HTTPMethod: "PUT",
  2570. HTTPPath: "/certificates/{certificateId}",
  2571. }
  2572. if input == nil {
  2573. input = &UpdateCertificateInput{}
  2574. }
  2575. req = c.newRequest(op, input, output)
  2576. req.Handlers.Unmarshal.Remove(restjson.UnmarshalHandler)
  2577. req.Handlers.Unmarshal.PushBackNamed(protocol.UnmarshalDiscardBodyHandler)
  2578. output = &UpdateCertificateOutput{}
  2579. req.Data = output
  2580. return
  2581. }
  2582. // Updates the status of the specified certificate. This operation is idempotent.
  2583. //
  2584. // Moving a certificate from the ACTIVE state (including REVOKED) will not
  2585. // disconnect currently connected devices, but these devices will be unable
  2586. // to reconnect.
  2587. //
  2588. // The ACTIVE state is required to authenticate devices connecting to AWS IoT
  2589. // using a certificate.
  2590. func (c *IoT) UpdateCertificate(input *UpdateCertificateInput) (*UpdateCertificateOutput, error) {
  2591. req, out := c.UpdateCertificateRequest(input)
  2592. err := req.Send()
  2593. return out, err
  2594. }
  2595. const opUpdateThing = "UpdateThing"
  2596. // UpdateThingRequest generates a "aws/request.Request" representing the
  2597. // client's request for the UpdateThing operation. The "output" return
  2598. // value can be used to capture response data after the request's "Send" method
  2599. // is called.
  2600. //
  2601. // Creating a request object using this method should be used when you want to inject
  2602. // custom logic into the request's lifecycle using a custom handler, or if you want to
  2603. // access properties on the request object before or after sending the request. If
  2604. // you just want the service response, call the UpdateThing method directly
  2605. // instead.
  2606. //
  2607. // Note: You must call the "Send" method on the returned request object in order
  2608. // to execute the request.
  2609. //
  2610. // // Example sending a request using the UpdateThingRequest method.
  2611. // req, resp := client.UpdateThingRequest(params)
  2612. //
  2613. // err := req.Send()
  2614. // if err == nil { // resp is now filled
  2615. // fmt.Println(resp)
  2616. // }
  2617. //
  2618. func (c *IoT) UpdateThingRequest(input *UpdateThingInput) (req *request.Request, output *UpdateThingOutput) {
  2619. op := &request.Operation{
  2620. Name: opUpdateThing,
  2621. HTTPMethod: "PATCH",
  2622. HTTPPath: "/things/{thingName}",
  2623. }
  2624. if input == nil {
  2625. input = &UpdateThingInput{}
  2626. }
  2627. req = c.newRequest(op, input, output)
  2628. output = &UpdateThingOutput{}
  2629. req.Data = output
  2630. return
  2631. }
  2632. // Updates the data for a thing.
  2633. func (c *IoT) UpdateThing(input *UpdateThingInput) (*UpdateThingOutput, error) {
  2634. req, out := c.UpdateThingRequest(input)
  2635. err := req.Send()
  2636. return out, err
  2637. }
  2638. // The input for the AcceptCertificateTransfer operation.
  2639. type AcceptCertificateTransferInput struct {
  2640. _ struct{} `type:"structure"`
  2641. // The ID of the certificate.
  2642. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  2643. // Specifies whether the certificate is active.
  2644. SetAsActive *bool `location:"querystring" locationName:"setAsActive" type:"boolean"`
  2645. }
  2646. // String returns the string representation
  2647. func (s AcceptCertificateTransferInput) String() string {
  2648. return awsutil.Prettify(s)
  2649. }
  2650. // GoString returns the string representation
  2651. func (s AcceptCertificateTransferInput) GoString() string {
  2652. return s.String()
  2653. }
  2654. // Validate inspects the fields of the type to determine if they are valid.
  2655. func (s *AcceptCertificateTransferInput) Validate() error {
  2656. invalidParams := request.ErrInvalidParams{Context: "AcceptCertificateTransferInput"}
  2657. if s.CertificateId == nil {
  2658. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  2659. }
  2660. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  2661. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  2662. }
  2663. if invalidParams.Len() > 0 {
  2664. return invalidParams
  2665. }
  2666. return nil
  2667. }
  2668. type AcceptCertificateTransferOutput struct {
  2669. _ struct{} `type:"structure"`
  2670. }
  2671. // String returns the string representation
  2672. func (s AcceptCertificateTransferOutput) String() string {
  2673. return awsutil.Prettify(s)
  2674. }
  2675. // GoString returns the string representation
  2676. func (s AcceptCertificateTransferOutput) GoString() string {
  2677. return s.String()
  2678. }
  2679. // Describes the actions associated with a rule.
  2680. type Action struct {
  2681. _ struct{} `type:"structure"`
  2682. // Change the state of a CloudWatch alarm.
  2683. CloudwatchAlarm *CloudwatchAlarmAction `locationName:"cloudwatchAlarm" type:"structure"`
  2684. // Capture a CloudWatch metric.
  2685. CloudwatchMetric *CloudwatchMetricAction `locationName:"cloudwatchMetric" type:"structure"`
  2686. // Write to a DynamoDB table.
  2687. DynamoDB *DynamoDBAction `locationName:"dynamoDB" type:"structure"`
  2688. // Write data to an Amazon Elasticsearch Service; domain.
  2689. Elasticsearch *ElasticsearchAction `locationName:"elasticsearch" type:"structure"`
  2690. // Write to an Amazon Kinesis Firehose stream.
  2691. Firehose *FirehoseAction `locationName:"firehose" type:"structure"`
  2692. // Write data to an Amazon Kinesis stream.
  2693. Kinesis *KinesisAction `locationName:"kinesis" type:"structure"`
  2694. // Invoke a Lambda function.
  2695. Lambda *LambdaAction `locationName:"lambda" type:"structure"`
  2696. // Publish to another MQTT topic.
  2697. Republish *RepublishAction `locationName:"republish" type:"structure"`
  2698. // Write to an Amazon S3 bucket.
  2699. S3 *S3Action `locationName:"s3" type:"structure"`
  2700. // Publish to an Amazon SNS topic.
  2701. Sns *SnsAction `locationName:"sns" type:"structure"`
  2702. // Publish to an Amazon SQS queue.
  2703. Sqs *SqsAction `locationName:"sqs" type:"structure"`
  2704. }
  2705. // String returns the string representation
  2706. func (s Action) String() string {
  2707. return awsutil.Prettify(s)
  2708. }
  2709. // GoString returns the string representation
  2710. func (s Action) GoString() string {
  2711. return s.String()
  2712. }
  2713. // Validate inspects the fields of the type to determine if they are valid.
  2714. func (s *Action) Validate() error {
  2715. invalidParams := request.ErrInvalidParams{Context: "Action"}
  2716. if s.CloudwatchAlarm != nil {
  2717. if err := s.CloudwatchAlarm.Validate(); err != nil {
  2718. invalidParams.AddNested("CloudwatchAlarm", err.(request.ErrInvalidParams))
  2719. }
  2720. }
  2721. if s.CloudwatchMetric != nil {
  2722. if err := s.CloudwatchMetric.Validate(); err != nil {
  2723. invalidParams.AddNested("CloudwatchMetric", err.(request.ErrInvalidParams))
  2724. }
  2725. }
  2726. if s.DynamoDB != nil {
  2727. if err := s.DynamoDB.Validate(); err != nil {
  2728. invalidParams.AddNested("DynamoDB", err.(request.ErrInvalidParams))
  2729. }
  2730. }
  2731. if s.Elasticsearch != nil {
  2732. if err := s.Elasticsearch.Validate(); err != nil {
  2733. invalidParams.AddNested("Elasticsearch", err.(request.ErrInvalidParams))
  2734. }
  2735. }
  2736. if s.Firehose != nil {
  2737. if err := s.Firehose.Validate(); err != nil {
  2738. invalidParams.AddNested("Firehose", err.(request.ErrInvalidParams))
  2739. }
  2740. }
  2741. if s.Kinesis != nil {
  2742. if err := s.Kinesis.Validate(); err != nil {
  2743. invalidParams.AddNested("Kinesis", err.(request.ErrInvalidParams))
  2744. }
  2745. }
  2746. if s.Lambda != nil {
  2747. if err := s.Lambda.Validate(); err != nil {
  2748. invalidParams.AddNested("Lambda", err.(request.ErrInvalidParams))
  2749. }
  2750. }
  2751. if s.Republish != nil {
  2752. if err := s.Republish.Validate(); err != nil {
  2753. invalidParams.AddNested("Republish", err.(request.ErrInvalidParams))
  2754. }
  2755. }
  2756. if s.S3 != nil {
  2757. if err := s.S3.Validate(); err != nil {
  2758. invalidParams.AddNested("S3", err.(request.ErrInvalidParams))
  2759. }
  2760. }
  2761. if s.Sns != nil {
  2762. if err := s.Sns.Validate(); err != nil {
  2763. invalidParams.AddNested("Sns", err.(request.ErrInvalidParams))
  2764. }
  2765. }
  2766. if s.Sqs != nil {
  2767. if err := s.Sqs.Validate(); err != nil {
  2768. invalidParams.AddNested("Sqs", err.(request.ErrInvalidParams))
  2769. }
  2770. }
  2771. if invalidParams.Len() > 0 {
  2772. return invalidParams
  2773. }
  2774. return nil
  2775. }
  2776. // The input for the AttachPrincipalPolicy operation.
  2777. type AttachPrincipalPolicyInput struct {
  2778. _ struct{} `type:"structure"`
  2779. // The policy name.
  2780. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  2781. // The principal, which can be a certificate ARN (as returned from the CreateCertificate
  2782. // operation) or an Amazon Cognito ID.
  2783. Principal *string `location:"header" locationName:"x-amzn-iot-principal" type:"string" required:"true"`
  2784. }
  2785. // String returns the string representation
  2786. func (s AttachPrincipalPolicyInput) String() string {
  2787. return awsutil.Prettify(s)
  2788. }
  2789. // GoString returns the string representation
  2790. func (s AttachPrincipalPolicyInput) GoString() string {
  2791. return s.String()
  2792. }
  2793. // Validate inspects the fields of the type to determine if they are valid.
  2794. func (s *AttachPrincipalPolicyInput) Validate() error {
  2795. invalidParams := request.ErrInvalidParams{Context: "AttachPrincipalPolicyInput"}
  2796. if s.PolicyName == nil {
  2797. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  2798. }
  2799. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  2800. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  2801. }
  2802. if s.Principal == nil {
  2803. invalidParams.Add(request.NewErrParamRequired("Principal"))
  2804. }
  2805. if invalidParams.Len() > 0 {
  2806. return invalidParams
  2807. }
  2808. return nil
  2809. }
  2810. type AttachPrincipalPolicyOutput struct {
  2811. _ struct{} `type:"structure"`
  2812. }
  2813. // String returns the string representation
  2814. func (s AttachPrincipalPolicyOutput) String() string {
  2815. return awsutil.Prettify(s)
  2816. }
  2817. // GoString returns the string representation
  2818. func (s AttachPrincipalPolicyOutput) GoString() string {
  2819. return s.String()
  2820. }
  2821. // The input for the AttachThingPrincipal operation.
  2822. type AttachThingPrincipalInput struct {
  2823. _ struct{} `type:"structure"`
  2824. // The principal, such as a certificate or other credential.
  2825. Principal *string `location:"header" locationName:"x-amzn-principal" type:"string" required:"true"`
  2826. // The name of the thing.
  2827. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  2828. }
  2829. // String returns the string representation
  2830. func (s AttachThingPrincipalInput) String() string {
  2831. return awsutil.Prettify(s)
  2832. }
  2833. // GoString returns the string representation
  2834. func (s AttachThingPrincipalInput) GoString() string {
  2835. return s.String()
  2836. }
  2837. // Validate inspects the fields of the type to determine if they are valid.
  2838. func (s *AttachThingPrincipalInput) Validate() error {
  2839. invalidParams := request.ErrInvalidParams{Context: "AttachThingPrincipalInput"}
  2840. if s.Principal == nil {
  2841. invalidParams.Add(request.NewErrParamRequired("Principal"))
  2842. }
  2843. if s.ThingName == nil {
  2844. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  2845. }
  2846. if s.ThingName != nil && len(*s.ThingName) < 1 {
  2847. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  2848. }
  2849. if invalidParams.Len() > 0 {
  2850. return invalidParams
  2851. }
  2852. return nil
  2853. }
  2854. // The output from the AttachThingPrincipal operation.
  2855. type AttachThingPrincipalOutput struct {
  2856. _ struct{} `type:"structure"`
  2857. }
  2858. // String returns the string representation
  2859. func (s AttachThingPrincipalOutput) String() string {
  2860. return awsutil.Prettify(s)
  2861. }
  2862. // GoString returns the string representation
  2863. func (s AttachThingPrincipalOutput) GoString() string {
  2864. return s.String()
  2865. }
  2866. // The attribute payload.
  2867. type AttributePayload struct {
  2868. _ struct{} `type:"structure"`
  2869. // A JSON string containing up to three key-value pair in JSON format. For example:
  2870. //
  2871. // {\"attributes\":{\"string1\":\"string2\"}})
  2872. Attributes map[string]*string `locationName:"attributes" type:"map"`
  2873. // Specifies whether the list of attributes provided in the AttributePayload
  2874. // is merged with the attributes stored in the registry, instead of overwriting
  2875. // them.
  2876. //
  2877. // To remove an attribute, call UpdateThing with an empty attribute value.
  2878. //
  2879. // The merge attribute is only valid when calling UpdateThing.
  2880. Merge *bool `locationName:"merge" type:"boolean"`
  2881. }
  2882. // String returns the string representation
  2883. func (s AttributePayload) String() string {
  2884. return awsutil.Prettify(s)
  2885. }
  2886. // GoString returns the string representation
  2887. func (s AttributePayload) GoString() string {
  2888. return s.String()
  2889. }
  2890. // A CA certificate.
  2891. type CACertificate struct {
  2892. _ struct{} `type:"structure"`
  2893. // The ARN of the CA certificate.
  2894. CertificateArn *string `locationName:"certificateArn" type:"string"`
  2895. // The ID of the CA certificate.
  2896. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  2897. // The date the CA certificate was created.
  2898. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"`
  2899. // The status of the CA certificate.
  2900. //
  2901. // The status value REGISTER_INACTIVE is deprecated and should not be used.
  2902. Status *string `locationName:"status" type:"string" enum:"CACertificateStatus"`
  2903. }
  2904. // String returns the string representation
  2905. func (s CACertificate) String() string {
  2906. return awsutil.Prettify(s)
  2907. }
  2908. // GoString returns the string representation
  2909. func (s CACertificate) GoString() string {
  2910. return s.String()
  2911. }
  2912. // Describes a CA certificate.
  2913. type CACertificateDescription struct {
  2914. _ struct{} `type:"structure"`
  2915. // Whether the CA certificate configured for auto registration of device certificates.
  2916. // Valid values are "ENABLE" and "DISABLE"
  2917. AutoRegistrationStatus *string `locationName:"autoRegistrationStatus" type:"string" enum:"AutoRegistrationStatus"`
  2918. // The CA certificate ARN.
  2919. CertificateArn *string `locationName:"certificateArn" type:"string"`
  2920. // The CA certificate ID.
  2921. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  2922. // The CA certificate data, in PEM format.
  2923. CertificatePem *string `locationName:"certificatePem" min:"1" type:"string"`
  2924. // The date the CA certificate was created.
  2925. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"`
  2926. // The owner of the CA certificate.
  2927. OwnedBy *string `locationName:"ownedBy" type:"string"`
  2928. // The status of a CA certificate.
  2929. Status *string `locationName:"status" type:"string" enum:"CACertificateStatus"`
  2930. }
  2931. // String returns the string representation
  2932. func (s CACertificateDescription) String() string {
  2933. return awsutil.Prettify(s)
  2934. }
  2935. // GoString returns the string representation
  2936. func (s CACertificateDescription) GoString() string {
  2937. return s.String()
  2938. }
  2939. // The input for the CancelCertificateTransfer operation.
  2940. type CancelCertificateTransferInput struct {
  2941. _ struct{} `type:"structure"`
  2942. // The ID of the certificate.
  2943. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  2944. }
  2945. // String returns the string representation
  2946. func (s CancelCertificateTransferInput) String() string {
  2947. return awsutil.Prettify(s)
  2948. }
  2949. // GoString returns the string representation
  2950. func (s CancelCertificateTransferInput) GoString() string {
  2951. return s.String()
  2952. }
  2953. // Validate inspects the fields of the type to determine if they are valid.
  2954. func (s *CancelCertificateTransferInput) Validate() error {
  2955. invalidParams := request.ErrInvalidParams{Context: "CancelCertificateTransferInput"}
  2956. if s.CertificateId == nil {
  2957. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  2958. }
  2959. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  2960. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  2961. }
  2962. if invalidParams.Len() > 0 {
  2963. return invalidParams
  2964. }
  2965. return nil
  2966. }
  2967. type CancelCertificateTransferOutput struct {
  2968. _ struct{} `type:"structure"`
  2969. }
  2970. // String returns the string representation
  2971. func (s CancelCertificateTransferOutput) String() string {
  2972. return awsutil.Prettify(s)
  2973. }
  2974. // GoString returns the string representation
  2975. func (s CancelCertificateTransferOutput) GoString() string {
  2976. return s.String()
  2977. }
  2978. // Information about a certificate.
  2979. type Certificate struct {
  2980. _ struct{} `type:"structure"`
  2981. // The ARN of the certificate.
  2982. CertificateArn *string `locationName:"certificateArn" type:"string"`
  2983. // The ID of the certificate.
  2984. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  2985. // The date and time the certificate was created.
  2986. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"`
  2987. // The status of the certificate.
  2988. //
  2989. // The status value REGISTER_INACTIVE is deprecated and should not be used.
  2990. Status *string `locationName:"status" type:"string" enum:"CertificateStatus"`
  2991. }
  2992. // String returns the string representation
  2993. func (s Certificate) String() string {
  2994. return awsutil.Prettify(s)
  2995. }
  2996. // GoString returns the string representation
  2997. func (s Certificate) GoString() string {
  2998. return s.String()
  2999. }
  3000. // Describes a certificate.
  3001. type CertificateDescription struct {
  3002. _ struct{} `type:"structure"`
  3003. // The certificate ID of the CA certificate used to sign this certificate.
  3004. CaCertificateId *string `locationName:"caCertificateId" min:"64" type:"string"`
  3005. // The ARN of the certificate.
  3006. CertificateArn *string `locationName:"certificateArn" type:"string"`
  3007. // The ID of the certificate.
  3008. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  3009. // The certificate data, in PEM format.
  3010. CertificatePem *string `locationName:"certificatePem" min:"1" type:"string"`
  3011. // The date and time the certificate was created.
  3012. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"`
  3013. // The date and time the certificate was last modified.
  3014. LastModifiedDate *time.Time `locationName:"lastModifiedDate" type:"timestamp" timestampFormat:"unix"`
  3015. // The ID of the AWS account that owns the certificate.
  3016. OwnedBy *string `locationName:"ownedBy" type:"string"`
  3017. // The ID of the AWS account of the previous owner of the certificate.
  3018. PreviousOwnedBy *string `locationName:"previousOwnedBy" type:"string"`
  3019. // The status of the certificate.
  3020. Status *string `locationName:"status" type:"string" enum:"CertificateStatus"`
  3021. // The transfer data.
  3022. TransferData *TransferData `locationName:"transferData" type:"structure"`
  3023. }
  3024. // String returns the string representation
  3025. func (s CertificateDescription) String() string {
  3026. return awsutil.Prettify(s)
  3027. }
  3028. // GoString returns the string representation
  3029. func (s CertificateDescription) GoString() string {
  3030. return s.String()
  3031. }
  3032. // Describes an action that updates a CloudWatch alarm.
  3033. type CloudwatchAlarmAction struct {
  3034. _ struct{} `type:"structure"`
  3035. // The CloudWatch alarm name.
  3036. AlarmName *string `locationName:"alarmName" type:"string" required:"true"`
  3037. // The IAM role that allows access to the CloudWatch alarm.
  3038. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  3039. // The reason for the alarm change.
  3040. StateReason *string `locationName:"stateReason" type:"string" required:"true"`
  3041. // The value of the alarm state. Acceptable values are: OK, ALARM, INSUFFICIENT_DATA.
  3042. StateValue *string `locationName:"stateValue" type:"string" required:"true"`
  3043. }
  3044. // String returns the string representation
  3045. func (s CloudwatchAlarmAction) String() string {
  3046. return awsutil.Prettify(s)
  3047. }
  3048. // GoString returns the string representation
  3049. func (s CloudwatchAlarmAction) GoString() string {
  3050. return s.String()
  3051. }
  3052. // Validate inspects the fields of the type to determine if they are valid.
  3053. func (s *CloudwatchAlarmAction) Validate() error {
  3054. invalidParams := request.ErrInvalidParams{Context: "CloudwatchAlarmAction"}
  3055. if s.AlarmName == nil {
  3056. invalidParams.Add(request.NewErrParamRequired("AlarmName"))
  3057. }
  3058. if s.RoleArn == nil {
  3059. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  3060. }
  3061. if s.StateReason == nil {
  3062. invalidParams.Add(request.NewErrParamRequired("StateReason"))
  3063. }
  3064. if s.StateValue == nil {
  3065. invalidParams.Add(request.NewErrParamRequired("StateValue"))
  3066. }
  3067. if invalidParams.Len() > 0 {
  3068. return invalidParams
  3069. }
  3070. return nil
  3071. }
  3072. // Describes an action that captures a CloudWatch metric.
  3073. type CloudwatchMetricAction struct {
  3074. _ struct{} `type:"structure"`
  3075. // The CloudWatch metric name.
  3076. MetricName *string `locationName:"metricName" type:"string" required:"true"`
  3077. // The CloudWatch metric namespace name.
  3078. MetricNamespace *string `locationName:"metricNamespace" type:"string" required:"true"`
  3079. // An optional Unix timestamp (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#about_timestamp).
  3080. MetricTimestamp *string `locationName:"metricTimestamp" type:"string"`
  3081. // The metric unit (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#Unit)
  3082. // supported by CloudWatch.
  3083. MetricUnit *string `locationName:"metricUnit" type:"string" required:"true"`
  3084. // The CloudWatch metric value.
  3085. MetricValue *string `locationName:"metricValue" type:"string" required:"true"`
  3086. // The IAM role that allows access to the CloudWatch metric.
  3087. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  3088. }
  3089. // String returns the string representation
  3090. func (s CloudwatchMetricAction) String() string {
  3091. return awsutil.Prettify(s)
  3092. }
  3093. // GoString returns the string representation
  3094. func (s CloudwatchMetricAction) GoString() string {
  3095. return s.String()
  3096. }
  3097. // Validate inspects the fields of the type to determine if they are valid.
  3098. func (s *CloudwatchMetricAction) Validate() error {
  3099. invalidParams := request.ErrInvalidParams{Context: "CloudwatchMetricAction"}
  3100. if s.MetricName == nil {
  3101. invalidParams.Add(request.NewErrParamRequired("MetricName"))
  3102. }
  3103. if s.MetricNamespace == nil {
  3104. invalidParams.Add(request.NewErrParamRequired("MetricNamespace"))
  3105. }
  3106. if s.MetricUnit == nil {
  3107. invalidParams.Add(request.NewErrParamRequired("MetricUnit"))
  3108. }
  3109. if s.MetricValue == nil {
  3110. invalidParams.Add(request.NewErrParamRequired("MetricValue"))
  3111. }
  3112. if s.RoleArn == nil {
  3113. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  3114. }
  3115. if invalidParams.Len() > 0 {
  3116. return invalidParams
  3117. }
  3118. return nil
  3119. }
  3120. // The input for the CreateCertificateFromCsr operation.
  3121. type CreateCertificateFromCsrInput struct {
  3122. _ struct{} `type:"structure"`
  3123. // The certificate signing request (CSR).
  3124. CertificateSigningRequest *string `locationName:"certificateSigningRequest" min:"1" type:"string" required:"true"`
  3125. // Specifies whether the certificate is active.
  3126. SetAsActive *bool `location:"querystring" locationName:"setAsActive" type:"boolean"`
  3127. }
  3128. // String returns the string representation
  3129. func (s CreateCertificateFromCsrInput) String() string {
  3130. return awsutil.Prettify(s)
  3131. }
  3132. // GoString returns the string representation
  3133. func (s CreateCertificateFromCsrInput) GoString() string {
  3134. return s.String()
  3135. }
  3136. // Validate inspects the fields of the type to determine if they are valid.
  3137. func (s *CreateCertificateFromCsrInput) Validate() error {
  3138. invalidParams := request.ErrInvalidParams{Context: "CreateCertificateFromCsrInput"}
  3139. if s.CertificateSigningRequest == nil {
  3140. invalidParams.Add(request.NewErrParamRequired("CertificateSigningRequest"))
  3141. }
  3142. if s.CertificateSigningRequest != nil && len(*s.CertificateSigningRequest) < 1 {
  3143. invalidParams.Add(request.NewErrParamMinLen("CertificateSigningRequest", 1))
  3144. }
  3145. if invalidParams.Len() > 0 {
  3146. return invalidParams
  3147. }
  3148. return nil
  3149. }
  3150. // The output from the CreateCertificateFromCsr operation.
  3151. type CreateCertificateFromCsrOutput struct {
  3152. _ struct{} `type:"structure"`
  3153. // The Amazon Resource Name (ARN) of the certificate. You can use the ARN as
  3154. // a principal for policy operations.
  3155. CertificateArn *string `locationName:"certificateArn" type:"string"`
  3156. // The ID of the certificate. Certificate management operations only take a
  3157. // certificateId.
  3158. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  3159. // The certificate data, in PEM format.
  3160. CertificatePem *string `locationName:"certificatePem" min:"1" type:"string"`
  3161. }
  3162. // String returns the string representation
  3163. func (s CreateCertificateFromCsrOutput) String() string {
  3164. return awsutil.Prettify(s)
  3165. }
  3166. // GoString returns the string representation
  3167. func (s CreateCertificateFromCsrOutput) GoString() string {
  3168. return s.String()
  3169. }
  3170. // The input for the CreateKeysAndCertificate operation.
  3171. type CreateKeysAndCertificateInput struct {
  3172. _ struct{} `type:"structure"`
  3173. // Specifies whether the certificate is active.
  3174. SetAsActive *bool `location:"querystring" locationName:"setAsActive" type:"boolean"`
  3175. }
  3176. // String returns the string representation
  3177. func (s CreateKeysAndCertificateInput) String() string {
  3178. return awsutil.Prettify(s)
  3179. }
  3180. // GoString returns the string representation
  3181. func (s CreateKeysAndCertificateInput) GoString() string {
  3182. return s.String()
  3183. }
  3184. // The output of the CreateKeysAndCertificate operation.
  3185. type CreateKeysAndCertificateOutput struct {
  3186. _ struct{} `type:"structure"`
  3187. // The ARN of the certificate.
  3188. CertificateArn *string `locationName:"certificateArn" type:"string"`
  3189. // The ID of the certificate. AWS IoT issues a default subject name for the
  3190. // certificate (for example, AWS IoT Certificate).
  3191. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  3192. // The certificate data, in PEM format.
  3193. CertificatePem *string `locationName:"certificatePem" min:"1" type:"string"`
  3194. // The generated key pair.
  3195. KeyPair *KeyPair `locationName:"keyPair" type:"structure"`
  3196. }
  3197. // String returns the string representation
  3198. func (s CreateKeysAndCertificateOutput) String() string {
  3199. return awsutil.Prettify(s)
  3200. }
  3201. // GoString returns the string representation
  3202. func (s CreateKeysAndCertificateOutput) GoString() string {
  3203. return s.String()
  3204. }
  3205. // The input for the CreatePolicy operation.
  3206. type CreatePolicyInput struct {
  3207. _ struct{} `type:"structure"`
  3208. // The JSON document that describes the policy. policyDocument must have a minimum
  3209. // length of 1, with a maximum length of 2048, excluding whitespace.
  3210. PolicyDocument *string `locationName:"policyDocument" type:"string" required:"true"`
  3211. // The policy name.
  3212. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  3213. }
  3214. // String returns the string representation
  3215. func (s CreatePolicyInput) String() string {
  3216. return awsutil.Prettify(s)
  3217. }
  3218. // GoString returns the string representation
  3219. func (s CreatePolicyInput) GoString() string {
  3220. return s.String()
  3221. }
  3222. // Validate inspects the fields of the type to determine if they are valid.
  3223. func (s *CreatePolicyInput) Validate() error {
  3224. invalidParams := request.ErrInvalidParams{Context: "CreatePolicyInput"}
  3225. if s.PolicyDocument == nil {
  3226. invalidParams.Add(request.NewErrParamRequired("PolicyDocument"))
  3227. }
  3228. if s.PolicyName == nil {
  3229. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  3230. }
  3231. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  3232. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  3233. }
  3234. if invalidParams.Len() > 0 {
  3235. return invalidParams
  3236. }
  3237. return nil
  3238. }
  3239. // The output from the CreatePolicy operation.
  3240. type CreatePolicyOutput struct {
  3241. _ struct{} `type:"structure"`
  3242. // The policy ARN.
  3243. PolicyArn *string `locationName:"policyArn" type:"string"`
  3244. // The JSON document that describes the policy.
  3245. PolicyDocument *string `locationName:"policyDocument" type:"string"`
  3246. // The policy name.
  3247. PolicyName *string `locationName:"policyName" min:"1" type:"string"`
  3248. // The policy version ID.
  3249. PolicyVersionId *string `locationName:"policyVersionId" type:"string"`
  3250. }
  3251. // String returns the string representation
  3252. func (s CreatePolicyOutput) String() string {
  3253. return awsutil.Prettify(s)
  3254. }
  3255. // GoString returns the string representation
  3256. func (s CreatePolicyOutput) GoString() string {
  3257. return s.String()
  3258. }
  3259. // The input for the CreatePolicyVersion operation.
  3260. type CreatePolicyVersionInput struct {
  3261. _ struct{} `type:"structure"`
  3262. // The JSON document that describes the policy. Minimum length of 1. Maximum
  3263. // length of 2048, excluding whitespaces
  3264. PolicyDocument *string `locationName:"policyDocument" type:"string" required:"true"`
  3265. // The policy name.
  3266. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  3267. // Specifies whether the policy version is set as the default. When this parameter
  3268. // is true, the new policy version becomes the operative version (that is, the
  3269. // version that is in effect for the certificates to which the policy is attached).
  3270. SetAsDefault *bool `location:"querystring" locationName:"setAsDefault" type:"boolean"`
  3271. }
  3272. // String returns the string representation
  3273. func (s CreatePolicyVersionInput) String() string {
  3274. return awsutil.Prettify(s)
  3275. }
  3276. // GoString returns the string representation
  3277. func (s CreatePolicyVersionInput) GoString() string {
  3278. return s.String()
  3279. }
  3280. // Validate inspects the fields of the type to determine if they are valid.
  3281. func (s *CreatePolicyVersionInput) Validate() error {
  3282. invalidParams := request.ErrInvalidParams{Context: "CreatePolicyVersionInput"}
  3283. if s.PolicyDocument == nil {
  3284. invalidParams.Add(request.NewErrParamRequired("PolicyDocument"))
  3285. }
  3286. if s.PolicyName == nil {
  3287. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  3288. }
  3289. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  3290. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  3291. }
  3292. if invalidParams.Len() > 0 {
  3293. return invalidParams
  3294. }
  3295. return nil
  3296. }
  3297. // The output of the CreatePolicyVersion operation.
  3298. type CreatePolicyVersionOutput struct {
  3299. _ struct{} `type:"structure"`
  3300. // Specifies whether the policy version is the default.
  3301. IsDefaultVersion *bool `locationName:"isDefaultVersion" type:"boolean"`
  3302. // The policy ARN.
  3303. PolicyArn *string `locationName:"policyArn" type:"string"`
  3304. // The JSON document that describes the policy.
  3305. PolicyDocument *string `locationName:"policyDocument" type:"string"`
  3306. // The policy version ID.
  3307. PolicyVersionId *string `locationName:"policyVersionId" type:"string"`
  3308. }
  3309. // String returns the string representation
  3310. func (s CreatePolicyVersionOutput) String() string {
  3311. return awsutil.Prettify(s)
  3312. }
  3313. // GoString returns the string representation
  3314. func (s CreatePolicyVersionOutput) GoString() string {
  3315. return s.String()
  3316. }
  3317. // The input for the CreateThing operation.
  3318. type CreateThingInput struct {
  3319. _ struct{} `type:"structure"`
  3320. // The attribute payload, which consists of up to three name/value pairs in
  3321. // a JSON document. For example:
  3322. //
  3323. // {\"attributes\":{\"string1\":\"string2\"}})
  3324. AttributePayload *AttributePayload `locationName:"attributePayload" type:"structure"`
  3325. // The name of the thing to create.
  3326. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  3327. // The name of the thing type associated with the new thing.
  3328. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  3329. }
  3330. // String returns the string representation
  3331. func (s CreateThingInput) String() string {
  3332. return awsutil.Prettify(s)
  3333. }
  3334. // GoString returns the string representation
  3335. func (s CreateThingInput) GoString() string {
  3336. return s.String()
  3337. }
  3338. // Validate inspects the fields of the type to determine if they are valid.
  3339. func (s *CreateThingInput) Validate() error {
  3340. invalidParams := request.ErrInvalidParams{Context: "CreateThingInput"}
  3341. if s.ThingName == nil {
  3342. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  3343. }
  3344. if s.ThingName != nil && len(*s.ThingName) < 1 {
  3345. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  3346. }
  3347. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  3348. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  3349. }
  3350. if invalidParams.Len() > 0 {
  3351. return invalidParams
  3352. }
  3353. return nil
  3354. }
  3355. // The output of the CreateThing operation.
  3356. type CreateThingOutput struct {
  3357. _ struct{} `type:"structure"`
  3358. // The ARN of the new thing.
  3359. ThingArn *string `locationName:"thingArn" type:"string"`
  3360. // The name of the new thing.
  3361. ThingName *string `locationName:"thingName" min:"1" type:"string"`
  3362. }
  3363. // String returns the string representation
  3364. func (s CreateThingOutput) String() string {
  3365. return awsutil.Prettify(s)
  3366. }
  3367. // GoString returns the string representation
  3368. func (s CreateThingOutput) GoString() string {
  3369. return s.String()
  3370. }
  3371. // The input for the CreateThingType operation.
  3372. type CreateThingTypeInput struct {
  3373. _ struct{} `type:"structure"`
  3374. // The name of the thing type.
  3375. ThingTypeName *string `location:"uri" locationName:"thingTypeName" min:"1" type:"string" required:"true"`
  3376. // The ThingTypeProperties for the thing type to create. It contains information
  3377. // about the new thing type including a description, and a list of searchable
  3378. // thing attribute names.
  3379. ThingTypeProperties *ThingTypeProperties `locationName:"thingTypeProperties" type:"structure"`
  3380. }
  3381. // String returns the string representation
  3382. func (s CreateThingTypeInput) String() string {
  3383. return awsutil.Prettify(s)
  3384. }
  3385. // GoString returns the string representation
  3386. func (s CreateThingTypeInput) GoString() string {
  3387. return s.String()
  3388. }
  3389. // Validate inspects the fields of the type to determine if they are valid.
  3390. func (s *CreateThingTypeInput) Validate() error {
  3391. invalidParams := request.ErrInvalidParams{Context: "CreateThingTypeInput"}
  3392. if s.ThingTypeName == nil {
  3393. invalidParams.Add(request.NewErrParamRequired("ThingTypeName"))
  3394. }
  3395. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  3396. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  3397. }
  3398. if invalidParams.Len() > 0 {
  3399. return invalidParams
  3400. }
  3401. return nil
  3402. }
  3403. // The output of the CreateThingType operation.
  3404. type CreateThingTypeOutput struct {
  3405. _ struct{} `type:"structure"`
  3406. // The Amazon Resource Name (ARN) of the thing type.
  3407. ThingTypeArn *string `locationName:"thingTypeArn" type:"string"`
  3408. // The name of the thing type.
  3409. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  3410. }
  3411. // String returns the string representation
  3412. func (s CreateThingTypeOutput) String() string {
  3413. return awsutil.Prettify(s)
  3414. }
  3415. // GoString returns the string representation
  3416. func (s CreateThingTypeOutput) GoString() string {
  3417. return s.String()
  3418. }
  3419. // The input for the CreateTopicRule operation.
  3420. type CreateTopicRuleInput struct {
  3421. _ struct{} `type:"structure" payload:"TopicRulePayload"`
  3422. // The name of the rule.
  3423. RuleName *string `location:"uri" locationName:"ruleName" min:"1" type:"string" required:"true"`
  3424. // The rule payload.
  3425. TopicRulePayload *TopicRulePayload `locationName:"topicRulePayload" type:"structure" required:"true"`
  3426. }
  3427. // String returns the string representation
  3428. func (s CreateTopicRuleInput) String() string {
  3429. return awsutil.Prettify(s)
  3430. }
  3431. // GoString returns the string representation
  3432. func (s CreateTopicRuleInput) GoString() string {
  3433. return s.String()
  3434. }
  3435. // Validate inspects the fields of the type to determine if they are valid.
  3436. func (s *CreateTopicRuleInput) Validate() error {
  3437. invalidParams := request.ErrInvalidParams{Context: "CreateTopicRuleInput"}
  3438. if s.RuleName == nil {
  3439. invalidParams.Add(request.NewErrParamRequired("RuleName"))
  3440. }
  3441. if s.RuleName != nil && len(*s.RuleName) < 1 {
  3442. invalidParams.Add(request.NewErrParamMinLen("RuleName", 1))
  3443. }
  3444. if s.TopicRulePayload == nil {
  3445. invalidParams.Add(request.NewErrParamRequired("TopicRulePayload"))
  3446. }
  3447. if s.TopicRulePayload != nil {
  3448. if err := s.TopicRulePayload.Validate(); err != nil {
  3449. invalidParams.AddNested("TopicRulePayload", err.(request.ErrInvalidParams))
  3450. }
  3451. }
  3452. if invalidParams.Len() > 0 {
  3453. return invalidParams
  3454. }
  3455. return nil
  3456. }
  3457. type CreateTopicRuleOutput struct {
  3458. _ struct{} `type:"structure"`
  3459. }
  3460. // String returns the string representation
  3461. func (s CreateTopicRuleOutput) String() string {
  3462. return awsutil.Prettify(s)
  3463. }
  3464. // GoString returns the string representation
  3465. func (s CreateTopicRuleOutput) GoString() string {
  3466. return s.String()
  3467. }
  3468. // Input for the DeleteCACertificate operation.
  3469. type DeleteCACertificateInput struct {
  3470. _ struct{} `type:"structure"`
  3471. // The ID of the certificate to delete.
  3472. CertificateId *string `location:"uri" locationName:"caCertificateId" min:"64" type:"string" required:"true"`
  3473. }
  3474. // String returns the string representation
  3475. func (s DeleteCACertificateInput) String() string {
  3476. return awsutil.Prettify(s)
  3477. }
  3478. // GoString returns the string representation
  3479. func (s DeleteCACertificateInput) GoString() string {
  3480. return s.String()
  3481. }
  3482. // Validate inspects the fields of the type to determine if they are valid.
  3483. func (s *DeleteCACertificateInput) Validate() error {
  3484. invalidParams := request.ErrInvalidParams{Context: "DeleteCACertificateInput"}
  3485. if s.CertificateId == nil {
  3486. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  3487. }
  3488. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  3489. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  3490. }
  3491. if invalidParams.Len() > 0 {
  3492. return invalidParams
  3493. }
  3494. return nil
  3495. }
  3496. // The output for the DeleteCACertificate operation.
  3497. type DeleteCACertificateOutput struct {
  3498. _ struct{} `type:"structure"`
  3499. }
  3500. // String returns the string representation
  3501. func (s DeleteCACertificateOutput) String() string {
  3502. return awsutil.Prettify(s)
  3503. }
  3504. // GoString returns the string representation
  3505. func (s DeleteCACertificateOutput) GoString() string {
  3506. return s.String()
  3507. }
  3508. // The input for the DeleteCertificate operation.
  3509. type DeleteCertificateInput struct {
  3510. _ struct{} `type:"structure"`
  3511. // The ID of the certificate.
  3512. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  3513. }
  3514. // String returns the string representation
  3515. func (s DeleteCertificateInput) String() string {
  3516. return awsutil.Prettify(s)
  3517. }
  3518. // GoString returns the string representation
  3519. func (s DeleteCertificateInput) GoString() string {
  3520. return s.String()
  3521. }
  3522. // Validate inspects the fields of the type to determine if they are valid.
  3523. func (s *DeleteCertificateInput) Validate() error {
  3524. invalidParams := request.ErrInvalidParams{Context: "DeleteCertificateInput"}
  3525. if s.CertificateId == nil {
  3526. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  3527. }
  3528. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  3529. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  3530. }
  3531. if invalidParams.Len() > 0 {
  3532. return invalidParams
  3533. }
  3534. return nil
  3535. }
  3536. type DeleteCertificateOutput struct {
  3537. _ struct{} `type:"structure"`
  3538. }
  3539. // String returns the string representation
  3540. func (s DeleteCertificateOutput) String() string {
  3541. return awsutil.Prettify(s)
  3542. }
  3543. // GoString returns the string representation
  3544. func (s DeleteCertificateOutput) GoString() string {
  3545. return s.String()
  3546. }
  3547. // The input for the DeletePolicy operation.
  3548. type DeletePolicyInput struct {
  3549. _ struct{} `type:"structure"`
  3550. // The name of the policy to delete.
  3551. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  3552. }
  3553. // String returns the string representation
  3554. func (s DeletePolicyInput) String() string {
  3555. return awsutil.Prettify(s)
  3556. }
  3557. // GoString returns the string representation
  3558. func (s DeletePolicyInput) GoString() string {
  3559. return s.String()
  3560. }
  3561. // Validate inspects the fields of the type to determine if they are valid.
  3562. func (s *DeletePolicyInput) Validate() error {
  3563. invalidParams := request.ErrInvalidParams{Context: "DeletePolicyInput"}
  3564. if s.PolicyName == nil {
  3565. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  3566. }
  3567. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  3568. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  3569. }
  3570. if invalidParams.Len() > 0 {
  3571. return invalidParams
  3572. }
  3573. return nil
  3574. }
  3575. type DeletePolicyOutput struct {
  3576. _ struct{} `type:"structure"`
  3577. }
  3578. // String returns the string representation
  3579. func (s DeletePolicyOutput) String() string {
  3580. return awsutil.Prettify(s)
  3581. }
  3582. // GoString returns the string representation
  3583. func (s DeletePolicyOutput) GoString() string {
  3584. return s.String()
  3585. }
  3586. // The input for the DeletePolicyVersion operation.
  3587. type DeletePolicyVersionInput struct {
  3588. _ struct{} `type:"structure"`
  3589. // The name of the policy.
  3590. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  3591. // The policy version ID.
  3592. PolicyVersionId *string `location:"uri" locationName:"policyVersionId" type:"string" required:"true"`
  3593. }
  3594. // String returns the string representation
  3595. func (s DeletePolicyVersionInput) String() string {
  3596. return awsutil.Prettify(s)
  3597. }
  3598. // GoString returns the string representation
  3599. func (s DeletePolicyVersionInput) GoString() string {
  3600. return s.String()
  3601. }
  3602. // Validate inspects the fields of the type to determine if they are valid.
  3603. func (s *DeletePolicyVersionInput) Validate() error {
  3604. invalidParams := request.ErrInvalidParams{Context: "DeletePolicyVersionInput"}
  3605. if s.PolicyName == nil {
  3606. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  3607. }
  3608. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  3609. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  3610. }
  3611. if s.PolicyVersionId == nil {
  3612. invalidParams.Add(request.NewErrParamRequired("PolicyVersionId"))
  3613. }
  3614. if invalidParams.Len() > 0 {
  3615. return invalidParams
  3616. }
  3617. return nil
  3618. }
  3619. type DeletePolicyVersionOutput struct {
  3620. _ struct{} `type:"structure"`
  3621. }
  3622. // String returns the string representation
  3623. func (s DeletePolicyVersionOutput) String() string {
  3624. return awsutil.Prettify(s)
  3625. }
  3626. // GoString returns the string representation
  3627. func (s DeletePolicyVersionOutput) GoString() string {
  3628. return s.String()
  3629. }
  3630. // The input for the DeleteRegistrationCode operation.
  3631. type DeleteRegistrationCodeInput struct {
  3632. _ struct{} `type:"structure"`
  3633. }
  3634. // String returns the string representation
  3635. func (s DeleteRegistrationCodeInput) String() string {
  3636. return awsutil.Prettify(s)
  3637. }
  3638. // GoString returns the string representation
  3639. func (s DeleteRegistrationCodeInput) GoString() string {
  3640. return s.String()
  3641. }
  3642. // The output for the DeleteRegistrationCode operation.
  3643. type DeleteRegistrationCodeOutput struct {
  3644. _ struct{} `type:"structure"`
  3645. }
  3646. // String returns the string representation
  3647. func (s DeleteRegistrationCodeOutput) String() string {
  3648. return awsutil.Prettify(s)
  3649. }
  3650. // GoString returns the string representation
  3651. func (s DeleteRegistrationCodeOutput) GoString() string {
  3652. return s.String()
  3653. }
  3654. // The input for the DeleteThing operation.
  3655. type DeleteThingInput struct {
  3656. _ struct{} `type:"structure"`
  3657. // The expected version of the thing record in the registry. If the version
  3658. // of the record in the registry does not match the expected version specified
  3659. // in the request, the DeleteThing request is rejected with a VersionConflictException.
  3660. ExpectedVersion *int64 `location:"querystring" locationName:"expectedVersion" type:"long"`
  3661. // The name of the thing to delete.
  3662. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  3663. }
  3664. // String returns the string representation
  3665. func (s DeleteThingInput) String() string {
  3666. return awsutil.Prettify(s)
  3667. }
  3668. // GoString returns the string representation
  3669. func (s DeleteThingInput) GoString() string {
  3670. return s.String()
  3671. }
  3672. // Validate inspects the fields of the type to determine if they are valid.
  3673. func (s *DeleteThingInput) Validate() error {
  3674. invalidParams := request.ErrInvalidParams{Context: "DeleteThingInput"}
  3675. if s.ThingName == nil {
  3676. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  3677. }
  3678. if s.ThingName != nil && len(*s.ThingName) < 1 {
  3679. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  3680. }
  3681. if invalidParams.Len() > 0 {
  3682. return invalidParams
  3683. }
  3684. return nil
  3685. }
  3686. // The output of the DeleteThing operation.
  3687. type DeleteThingOutput struct {
  3688. _ struct{} `type:"structure"`
  3689. }
  3690. // String returns the string representation
  3691. func (s DeleteThingOutput) String() string {
  3692. return awsutil.Prettify(s)
  3693. }
  3694. // GoString returns the string representation
  3695. func (s DeleteThingOutput) GoString() string {
  3696. return s.String()
  3697. }
  3698. // The input for the DeleteThingType operation.
  3699. type DeleteThingTypeInput struct {
  3700. _ struct{} `type:"structure"`
  3701. // The name of the thing type.
  3702. ThingTypeName *string `location:"uri" locationName:"thingTypeName" min:"1" type:"string" required:"true"`
  3703. }
  3704. // String returns the string representation
  3705. func (s DeleteThingTypeInput) String() string {
  3706. return awsutil.Prettify(s)
  3707. }
  3708. // GoString returns the string representation
  3709. func (s DeleteThingTypeInput) GoString() string {
  3710. return s.String()
  3711. }
  3712. // Validate inspects the fields of the type to determine if they are valid.
  3713. func (s *DeleteThingTypeInput) Validate() error {
  3714. invalidParams := request.ErrInvalidParams{Context: "DeleteThingTypeInput"}
  3715. if s.ThingTypeName == nil {
  3716. invalidParams.Add(request.NewErrParamRequired("ThingTypeName"))
  3717. }
  3718. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  3719. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  3720. }
  3721. if invalidParams.Len() > 0 {
  3722. return invalidParams
  3723. }
  3724. return nil
  3725. }
  3726. // The output for the DeleteThingType operation.
  3727. type DeleteThingTypeOutput struct {
  3728. _ struct{} `type:"structure"`
  3729. }
  3730. // String returns the string representation
  3731. func (s DeleteThingTypeOutput) String() string {
  3732. return awsutil.Prettify(s)
  3733. }
  3734. // GoString returns the string representation
  3735. func (s DeleteThingTypeOutput) GoString() string {
  3736. return s.String()
  3737. }
  3738. // The input for the DeleteTopicRule operation.
  3739. type DeleteTopicRuleInput struct {
  3740. _ struct{} `type:"structure"`
  3741. // The name of the rule.
  3742. RuleName *string `location:"uri" locationName:"ruleName" min:"1" type:"string" required:"true"`
  3743. }
  3744. // String returns the string representation
  3745. func (s DeleteTopicRuleInput) String() string {
  3746. return awsutil.Prettify(s)
  3747. }
  3748. // GoString returns the string representation
  3749. func (s DeleteTopicRuleInput) GoString() string {
  3750. return s.String()
  3751. }
  3752. // Validate inspects the fields of the type to determine if they are valid.
  3753. func (s *DeleteTopicRuleInput) Validate() error {
  3754. invalidParams := request.ErrInvalidParams{Context: "DeleteTopicRuleInput"}
  3755. if s.RuleName == nil {
  3756. invalidParams.Add(request.NewErrParamRequired("RuleName"))
  3757. }
  3758. if s.RuleName != nil && len(*s.RuleName) < 1 {
  3759. invalidParams.Add(request.NewErrParamMinLen("RuleName", 1))
  3760. }
  3761. if invalidParams.Len() > 0 {
  3762. return invalidParams
  3763. }
  3764. return nil
  3765. }
  3766. type DeleteTopicRuleOutput struct {
  3767. _ struct{} `type:"structure"`
  3768. }
  3769. // String returns the string representation
  3770. func (s DeleteTopicRuleOutput) String() string {
  3771. return awsutil.Prettify(s)
  3772. }
  3773. // GoString returns the string representation
  3774. func (s DeleteTopicRuleOutput) GoString() string {
  3775. return s.String()
  3776. }
  3777. // The input for the DeprecateThingType operation.
  3778. type DeprecateThingTypeInput struct {
  3779. _ struct{} `type:"structure"`
  3780. // The name of the thing type to deprecate.
  3781. ThingTypeName *string `location:"uri" locationName:"thingTypeName" min:"1" type:"string" required:"true"`
  3782. // Whether to undeprecate a deprecated thing type. If true, the thing type will
  3783. // not be deprecated anymore and you can associate it with things.
  3784. UndoDeprecate *bool `locationName:"undoDeprecate" type:"boolean"`
  3785. }
  3786. // String returns the string representation
  3787. func (s DeprecateThingTypeInput) String() string {
  3788. return awsutil.Prettify(s)
  3789. }
  3790. // GoString returns the string representation
  3791. func (s DeprecateThingTypeInput) GoString() string {
  3792. return s.String()
  3793. }
  3794. // Validate inspects the fields of the type to determine if they are valid.
  3795. func (s *DeprecateThingTypeInput) Validate() error {
  3796. invalidParams := request.ErrInvalidParams{Context: "DeprecateThingTypeInput"}
  3797. if s.ThingTypeName == nil {
  3798. invalidParams.Add(request.NewErrParamRequired("ThingTypeName"))
  3799. }
  3800. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  3801. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  3802. }
  3803. if invalidParams.Len() > 0 {
  3804. return invalidParams
  3805. }
  3806. return nil
  3807. }
  3808. // The output for the DeprecateThingType operation.
  3809. type DeprecateThingTypeOutput struct {
  3810. _ struct{} `type:"structure"`
  3811. }
  3812. // String returns the string representation
  3813. func (s DeprecateThingTypeOutput) String() string {
  3814. return awsutil.Prettify(s)
  3815. }
  3816. // GoString returns the string representation
  3817. func (s DeprecateThingTypeOutput) GoString() string {
  3818. return s.String()
  3819. }
  3820. // The input for the DescribeCACertificate operation.
  3821. type DescribeCACertificateInput struct {
  3822. _ struct{} `type:"structure"`
  3823. // The CA certificate identifier.
  3824. CertificateId *string `location:"uri" locationName:"caCertificateId" min:"64" type:"string" required:"true"`
  3825. }
  3826. // String returns the string representation
  3827. func (s DescribeCACertificateInput) String() string {
  3828. return awsutil.Prettify(s)
  3829. }
  3830. // GoString returns the string representation
  3831. func (s DescribeCACertificateInput) GoString() string {
  3832. return s.String()
  3833. }
  3834. // Validate inspects the fields of the type to determine if they are valid.
  3835. func (s *DescribeCACertificateInput) Validate() error {
  3836. invalidParams := request.ErrInvalidParams{Context: "DescribeCACertificateInput"}
  3837. if s.CertificateId == nil {
  3838. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  3839. }
  3840. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  3841. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  3842. }
  3843. if invalidParams.Len() > 0 {
  3844. return invalidParams
  3845. }
  3846. return nil
  3847. }
  3848. // The output from the DescribeCACertificate operation.
  3849. type DescribeCACertificateOutput struct {
  3850. _ struct{} `type:"structure"`
  3851. // The CA certificate description.
  3852. CertificateDescription *CACertificateDescription `locationName:"certificateDescription" type:"structure"`
  3853. }
  3854. // String returns the string representation
  3855. func (s DescribeCACertificateOutput) String() string {
  3856. return awsutil.Prettify(s)
  3857. }
  3858. // GoString returns the string representation
  3859. func (s DescribeCACertificateOutput) GoString() string {
  3860. return s.String()
  3861. }
  3862. // The input for the DescribeCertificate operation.
  3863. type DescribeCertificateInput struct {
  3864. _ struct{} `type:"structure"`
  3865. // The ID of the certificate.
  3866. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  3867. }
  3868. // String returns the string representation
  3869. func (s DescribeCertificateInput) String() string {
  3870. return awsutil.Prettify(s)
  3871. }
  3872. // GoString returns the string representation
  3873. func (s DescribeCertificateInput) GoString() string {
  3874. return s.String()
  3875. }
  3876. // Validate inspects the fields of the type to determine if they are valid.
  3877. func (s *DescribeCertificateInput) Validate() error {
  3878. invalidParams := request.ErrInvalidParams{Context: "DescribeCertificateInput"}
  3879. if s.CertificateId == nil {
  3880. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  3881. }
  3882. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  3883. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  3884. }
  3885. if invalidParams.Len() > 0 {
  3886. return invalidParams
  3887. }
  3888. return nil
  3889. }
  3890. // The output of the DescribeCertificate operation.
  3891. type DescribeCertificateOutput struct {
  3892. _ struct{} `type:"structure"`
  3893. // The description of the certificate.
  3894. CertificateDescription *CertificateDescription `locationName:"certificateDescription" type:"structure"`
  3895. }
  3896. // String returns the string representation
  3897. func (s DescribeCertificateOutput) String() string {
  3898. return awsutil.Prettify(s)
  3899. }
  3900. // GoString returns the string representation
  3901. func (s DescribeCertificateOutput) GoString() string {
  3902. return s.String()
  3903. }
  3904. // The input for the DescribeEndpoint operation.
  3905. type DescribeEndpointInput struct {
  3906. _ struct{} `type:"structure"`
  3907. }
  3908. // String returns the string representation
  3909. func (s DescribeEndpointInput) String() string {
  3910. return awsutil.Prettify(s)
  3911. }
  3912. // GoString returns the string representation
  3913. func (s DescribeEndpointInput) GoString() string {
  3914. return s.String()
  3915. }
  3916. // The output from the DescribeEndpoint operation.
  3917. type DescribeEndpointOutput struct {
  3918. _ struct{} `type:"structure"`
  3919. // The endpoint. The format of the endpoint is as follows: identifier.iot.region.amazonaws.com.
  3920. EndpointAddress *string `locationName:"endpointAddress" type:"string"`
  3921. }
  3922. // String returns the string representation
  3923. func (s DescribeEndpointOutput) String() string {
  3924. return awsutil.Prettify(s)
  3925. }
  3926. // GoString returns the string representation
  3927. func (s DescribeEndpointOutput) GoString() string {
  3928. return s.String()
  3929. }
  3930. // The input for the DescribeThing operation.
  3931. type DescribeThingInput struct {
  3932. _ struct{} `type:"structure"`
  3933. // The name of the thing.
  3934. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  3935. }
  3936. // String returns the string representation
  3937. func (s DescribeThingInput) String() string {
  3938. return awsutil.Prettify(s)
  3939. }
  3940. // GoString returns the string representation
  3941. func (s DescribeThingInput) GoString() string {
  3942. return s.String()
  3943. }
  3944. // Validate inspects the fields of the type to determine if they are valid.
  3945. func (s *DescribeThingInput) Validate() error {
  3946. invalidParams := request.ErrInvalidParams{Context: "DescribeThingInput"}
  3947. if s.ThingName == nil {
  3948. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  3949. }
  3950. if s.ThingName != nil && len(*s.ThingName) < 1 {
  3951. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  3952. }
  3953. if invalidParams.Len() > 0 {
  3954. return invalidParams
  3955. }
  3956. return nil
  3957. }
  3958. // The output from the DescribeThing operation.
  3959. type DescribeThingOutput struct {
  3960. _ struct{} `type:"structure"`
  3961. // The thing attributes.
  3962. Attributes map[string]*string `locationName:"attributes" type:"map"`
  3963. // The default client ID.
  3964. DefaultClientId *string `locationName:"defaultClientId" type:"string"`
  3965. // The name of the thing.
  3966. ThingName *string `locationName:"thingName" min:"1" type:"string"`
  3967. // The thing type name.
  3968. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  3969. // The current version of the thing record in the registry.
  3970. //
  3971. // To avoid unintentional changes to the information in the registry, you
  3972. // can pass the version information in the expectedVersion parameter of the
  3973. // UpdateThing and DeleteThing calls.
  3974. Version *int64 `locationName:"version" type:"long"`
  3975. }
  3976. // String returns the string representation
  3977. func (s DescribeThingOutput) String() string {
  3978. return awsutil.Prettify(s)
  3979. }
  3980. // GoString returns the string representation
  3981. func (s DescribeThingOutput) GoString() string {
  3982. return s.String()
  3983. }
  3984. // The input for the DescribeThingType operation.
  3985. type DescribeThingTypeInput struct {
  3986. _ struct{} `type:"structure"`
  3987. // The name of the thing type.
  3988. ThingTypeName *string `location:"uri" locationName:"thingTypeName" min:"1" type:"string" required:"true"`
  3989. }
  3990. // String returns the string representation
  3991. func (s DescribeThingTypeInput) String() string {
  3992. return awsutil.Prettify(s)
  3993. }
  3994. // GoString returns the string representation
  3995. func (s DescribeThingTypeInput) GoString() string {
  3996. return s.String()
  3997. }
  3998. // Validate inspects the fields of the type to determine if they are valid.
  3999. func (s *DescribeThingTypeInput) Validate() error {
  4000. invalidParams := request.ErrInvalidParams{Context: "DescribeThingTypeInput"}
  4001. if s.ThingTypeName == nil {
  4002. invalidParams.Add(request.NewErrParamRequired("ThingTypeName"))
  4003. }
  4004. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  4005. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  4006. }
  4007. if invalidParams.Len() > 0 {
  4008. return invalidParams
  4009. }
  4010. return nil
  4011. }
  4012. // The output for the DescribeThingType operation.
  4013. type DescribeThingTypeOutput struct {
  4014. _ struct{} `type:"structure"`
  4015. // The ThingTypeMetadata contains additional information about the thing type
  4016. // including: creation date and time, a value indicating whether the thing type
  4017. // is deprecated, and a date and time when time was deprecated.
  4018. ThingTypeMetadata *ThingTypeMetadata `locationName:"thingTypeMetadata" type:"structure"`
  4019. // The name of the thing type.
  4020. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  4021. // The ThingTypeProperties contains information about the thing type including
  4022. // description, and a list of searchable thing attribute names.
  4023. ThingTypeProperties *ThingTypeProperties `locationName:"thingTypeProperties" type:"structure"`
  4024. }
  4025. // String returns the string representation
  4026. func (s DescribeThingTypeOutput) String() string {
  4027. return awsutil.Prettify(s)
  4028. }
  4029. // GoString returns the string representation
  4030. func (s DescribeThingTypeOutput) GoString() string {
  4031. return s.String()
  4032. }
  4033. // The input for the DetachPrincipalPolicy operation.
  4034. type DetachPrincipalPolicyInput struct {
  4035. _ struct{} `type:"structure"`
  4036. // The name of the policy to detach.
  4037. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  4038. // The principal.
  4039. //
  4040. // If the principal is a certificate, specify the certificate ARN. If the principal
  4041. // is an Amazon Cognito identity, specify the identity ID.
  4042. Principal *string `location:"header" locationName:"x-amzn-iot-principal" type:"string" required:"true"`
  4043. }
  4044. // String returns the string representation
  4045. func (s DetachPrincipalPolicyInput) String() string {
  4046. return awsutil.Prettify(s)
  4047. }
  4048. // GoString returns the string representation
  4049. func (s DetachPrincipalPolicyInput) GoString() string {
  4050. return s.String()
  4051. }
  4052. // Validate inspects the fields of the type to determine if they are valid.
  4053. func (s *DetachPrincipalPolicyInput) Validate() error {
  4054. invalidParams := request.ErrInvalidParams{Context: "DetachPrincipalPolicyInput"}
  4055. if s.PolicyName == nil {
  4056. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  4057. }
  4058. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  4059. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  4060. }
  4061. if s.Principal == nil {
  4062. invalidParams.Add(request.NewErrParamRequired("Principal"))
  4063. }
  4064. if invalidParams.Len() > 0 {
  4065. return invalidParams
  4066. }
  4067. return nil
  4068. }
  4069. type DetachPrincipalPolicyOutput struct {
  4070. _ struct{} `type:"structure"`
  4071. }
  4072. // String returns the string representation
  4073. func (s DetachPrincipalPolicyOutput) String() string {
  4074. return awsutil.Prettify(s)
  4075. }
  4076. // GoString returns the string representation
  4077. func (s DetachPrincipalPolicyOutput) GoString() string {
  4078. return s.String()
  4079. }
  4080. // The input for the DetachThingPrincipal operation.
  4081. type DetachThingPrincipalInput struct {
  4082. _ struct{} `type:"structure"`
  4083. // If the principal is a certificate, this value must be ARN of the certificate.
  4084. // If the principal is an Amazon Cognito identity, this value must be the ID
  4085. // of the Amazon Cognito identity.
  4086. Principal *string `location:"header" locationName:"x-amzn-principal" type:"string" required:"true"`
  4087. // The name of the thing.
  4088. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  4089. }
  4090. // String returns the string representation
  4091. func (s DetachThingPrincipalInput) String() string {
  4092. return awsutil.Prettify(s)
  4093. }
  4094. // GoString returns the string representation
  4095. func (s DetachThingPrincipalInput) GoString() string {
  4096. return s.String()
  4097. }
  4098. // Validate inspects the fields of the type to determine if they are valid.
  4099. func (s *DetachThingPrincipalInput) Validate() error {
  4100. invalidParams := request.ErrInvalidParams{Context: "DetachThingPrincipalInput"}
  4101. if s.Principal == nil {
  4102. invalidParams.Add(request.NewErrParamRequired("Principal"))
  4103. }
  4104. if s.ThingName == nil {
  4105. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  4106. }
  4107. if s.ThingName != nil && len(*s.ThingName) < 1 {
  4108. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  4109. }
  4110. if invalidParams.Len() > 0 {
  4111. return invalidParams
  4112. }
  4113. return nil
  4114. }
  4115. // The output from the DetachThingPrincipal operation.
  4116. type DetachThingPrincipalOutput struct {
  4117. _ struct{} `type:"structure"`
  4118. }
  4119. // String returns the string representation
  4120. func (s DetachThingPrincipalOutput) String() string {
  4121. return awsutil.Prettify(s)
  4122. }
  4123. // GoString returns the string representation
  4124. func (s DetachThingPrincipalOutput) GoString() string {
  4125. return s.String()
  4126. }
  4127. // The input for the DisableTopicRuleRequest operation.
  4128. type DisableTopicRuleInput struct {
  4129. _ struct{} `type:"structure"`
  4130. // The name of the rule to disable.
  4131. RuleName *string `location:"uri" locationName:"ruleName" min:"1" type:"string" required:"true"`
  4132. }
  4133. // String returns the string representation
  4134. func (s DisableTopicRuleInput) String() string {
  4135. return awsutil.Prettify(s)
  4136. }
  4137. // GoString returns the string representation
  4138. func (s DisableTopicRuleInput) GoString() string {
  4139. return s.String()
  4140. }
  4141. // Validate inspects the fields of the type to determine if they are valid.
  4142. func (s *DisableTopicRuleInput) Validate() error {
  4143. invalidParams := request.ErrInvalidParams{Context: "DisableTopicRuleInput"}
  4144. if s.RuleName == nil {
  4145. invalidParams.Add(request.NewErrParamRequired("RuleName"))
  4146. }
  4147. if s.RuleName != nil && len(*s.RuleName) < 1 {
  4148. invalidParams.Add(request.NewErrParamMinLen("RuleName", 1))
  4149. }
  4150. if invalidParams.Len() > 0 {
  4151. return invalidParams
  4152. }
  4153. return nil
  4154. }
  4155. type DisableTopicRuleOutput struct {
  4156. _ struct{} `type:"structure"`
  4157. }
  4158. // String returns the string representation
  4159. func (s DisableTopicRuleOutput) String() string {
  4160. return awsutil.Prettify(s)
  4161. }
  4162. // GoString returns the string representation
  4163. func (s DisableTopicRuleOutput) GoString() string {
  4164. return s.String()
  4165. }
  4166. // Describes an action to write to a DynamoDB table.
  4167. //
  4168. // The tableName, hashKeyField, and rangeKeyField values must match the values
  4169. // used when you created the table.
  4170. //
  4171. // The hashKeyValue and rangeKeyvalue fields use a substitution template syntax.
  4172. // These templates provide data at runtime. The syntax is as follows: ${sql-expression}.
  4173. //
  4174. // You can specify any valid expression in a WHERE or SELECT clause, including
  4175. // JSON properties, comparisons, calculations, and functions. For example, the
  4176. // following field uses the third level of the topic:
  4177. //
  4178. // "hashKeyValue": "${topic(3)}"
  4179. //
  4180. // The following field uses the timestamp:
  4181. //
  4182. // "rangeKeyValue": "${timestamp()}"
  4183. type DynamoDBAction struct {
  4184. _ struct{} `type:"structure"`
  4185. // The hash key name.
  4186. HashKeyField *string `locationName:"hashKeyField" type:"string" required:"true"`
  4187. // The hash key type. Valid values are "STRING" or "NUMBER"
  4188. HashKeyType *string `locationName:"hashKeyType" type:"string" enum:"DynamoKeyType"`
  4189. // The hash key value.
  4190. HashKeyValue *string `locationName:"hashKeyValue" type:"string" required:"true"`
  4191. // The type of operation to be performed. This follows the substitution template,
  4192. // so it can be ${operation}, but the substitution must result in one of the
  4193. // following: INSERT, UPDATE, or DELETE.
  4194. Operation *string `locationName:"operation" type:"string"`
  4195. // The action payload. This name can be customized.
  4196. PayloadField *string `locationName:"payloadField" type:"string"`
  4197. // The range key name.
  4198. RangeKeyField *string `locationName:"rangeKeyField" type:"string"`
  4199. // The range key type. Valid values are "STRING" or "NUMBER"
  4200. RangeKeyType *string `locationName:"rangeKeyType" type:"string" enum:"DynamoKeyType"`
  4201. // The range key value.
  4202. RangeKeyValue *string `locationName:"rangeKeyValue" type:"string"`
  4203. // The ARN of the IAM role that grants access to the DynamoDB table.
  4204. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  4205. // The name of the DynamoDB table.
  4206. TableName *string `locationName:"tableName" type:"string" required:"true"`
  4207. }
  4208. // String returns the string representation
  4209. func (s DynamoDBAction) String() string {
  4210. return awsutil.Prettify(s)
  4211. }
  4212. // GoString returns the string representation
  4213. func (s DynamoDBAction) GoString() string {
  4214. return s.String()
  4215. }
  4216. // Validate inspects the fields of the type to determine if they are valid.
  4217. func (s *DynamoDBAction) Validate() error {
  4218. invalidParams := request.ErrInvalidParams{Context: "DynamoDBAction"}
  4219. if s.HashKeyField == nil {
  4220. invalidParams.Add(request.NewErrParamRequired("HashKeyField"))
  4221. }
  4222. if s.HashKeyValue == nil {
  4223. invalidParams.Add(request.NewErrParamRequired("HashKeyValue"))
  4224. }
  4225. if s.RoleArn == nil {
  4226. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  4227. }
  4228. if s.TableName == nil {
  4229. invalidParams.Add(request.NewErrParamRequired("TableName"))
  4230. }
  4231. if invalidParams.Len() > 0 {
  4232. return invalidParams
  4233. }
  4234. return nil
  4235. }
  4236. // Describes an action that writes data to an Amazon Elasticsearch Service;
  4237. // domain.
  4238. type ElasticsearchAction struct {
  4239. _ struct{} `type:"structure"`
  4240. // The endpoint of your Elasticsearch domain.
  4241. Endpoint *string `locationName:"endpoint" type:"string" required:"true"`
  4242. // The unique identifier for the document you are storing.
  4243. Id *string `locationName:"id" type:"string" required:"true"`
  4244. // The Elasticsearch index where you want to store your data.
  4245. Index *string `locationName:"index" type:"string" required:"true"`
  4246. // The IAM role ARN that has access to Elasticsearch.
  4247. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  4248. // The type of document you are storing.
  4249. Type *string `locationName:"type" type:"string" required:"true"`
  4250. }
  4251. // String returns the string representation
  4252. func (s ElasticsearchAction) String() string {
  4253. return awsutil.Prettify(s)
  4254. }
  4255. // GoString returns the string representation
  4256. func (s ElasticsearchAction) GoString() string {
  4257. return s.String()
  4258. }
  4259. // Validate inspects the fields of the type to determine if they are valid.
  4260. func (s *ElasticsearchAction) Validate() error {
  4261. invalidParams := request.ErrInvalidParams{Context: "ElasticsearchAction"}
  4262. if s.Endpoint == nil {
  4263. invalidParams.Add(request.NewErrParamRequired("Endpoint"))
  4264. }
  4265. if s.Id == nil {
  4266. invalidParams.Add(request.NewErrParamRequired("Id"))
  4267. }
  4268. if s.Index == nil {
  4269. invalidParams.Add(request.NewErrParamRequired("Index"))
  4270. }
  4271. if s.RoleArn == nil {
  4272. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  4273. }
  4274. if s.Type == nil {
  4275. invalidParams.Add(request.NewErrParamRequired("Type"))
  4276. }
  4277. if invalidParams.Len() > 0 {
  4278. return invalidParams
  4279. }
  4280. return nil
  4281. }
  4282. // The input for the EnableTopicRuleRequest operation.
  4283. type EnableTopicRuleInput struct {
  4284. _ struct{} `type:"structure"`
  4285. // The name of the topic rule to enable.
  4286. RuleName *string `location:"uri" locationName:"ruleName" min:"1" type:"string" required:"true"`
  4287. }
  4288. // String returns the string representation
  4289. func (s EnableTopicRuleInput) String() string {
  4290. return awsutil.Prettify(s)
  4291. }
  4292. // GoString returns the string representation
  4293. func (s EnableTopicRuleInput) GoString() string {
  4294. return s.String()
  4295. }
  4296. // Validate inspects the fields of the type to determine if they are valid.
  4297. func (s *EnableTopicRuleInput) Validate() error {
  4298. invalidParams := request.ErrInvalidParams{Context: "EnableTopicRuleInput"}
  4299. if s.RuleName == nil {
  4300. invalidParams.Add(request.NewErrParamRequired("RuleName"))
  4301. }
  4302. if s.RuleName != nil && len(*s.RuleName) < 1 {
  4303. invalidParams.Add(request.NewErrParamMinLen("RuleName", 1))
  4304. }
  4305. if invalidParams.Len() > 0 {
  4306. return invalidParams
  4307. }
  4308. return nil
  4309. }
  4310. type EnableTopicRuleOutput struct {
  4311. _ struct{} `type:"structure"`
  4312. }
  4313. // String returns the string representation
  4314. func (s EnableTopicRuleOutput) String() string {
  4315. return awsutil.Prettify(s)
  4316. }
  4317. // GoString returns the string representation
  4318. func (s EnableTopicRuleOutput) GoString() string {
  4319. return s.String()
  4320. }
  4321. // Describes an action that writes data to an Amazon Kinesis Firehose stream.
  4322. type FirehoseAction struct {
  4323. _ struct{} `type:"structure"`
  4324. // The delivery stream name.
  4325. DeliveryStreamName *string `locationName:"deliveryStreamName" type:"string" required:"true"`
  4326. // The IAM role that grants access to the Amazon Kinesis Firehost stream.
  4327. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  4328. // A character separator that will be used to separate records written to the
  4329. // firehose stream. Valid values are: '\n' (newline), '\t' (tab), '\r\n' (Windows
  4330. // newline), ',' (comma).
  4331. Separator *string `locationName:"separator" type:"string"`
  4332. }
  4333. // String returns the string representation
  4334. func (s FirehoseAction) String() string {
  4335. return awsutil.Prettify(s)
  4336. }
  4337. // GoString returns the string representation
  4338. func (s FirehoseAction) GoString() string {
  4339. return s.String()
  4340. }
  4341. // Validate inspects the fields of the type to determine if they are valid.
  4342. func (s *FirehoseAction) Validate() error {
  4343. invalidParams := request.ErrInvalidParams{Context: "FirehoseAction"}
  4344. if s.DeliveryStreamName == nil {
  4345. invalidParams.Add(request.NewErrParamRequired("DeliveryStreamName"))
  4346. }
  4347. if s.RoleArn == nil {
  4348. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  4349. }
  4350. if invalidParams.Len() > 0 {
  4351. return invalidParams
  4352. }
  4353. return nil
  4354. }
  4355. // The input for the GetLoggingOptions operation.
  4356. type GetLoggingOptionsInput struct {
  4357. _ struct{} `type:"structure"`
  4358. }
  4359. // String returns the string representation
  4360. func (s GetLoggingOptionsInput) String() string {
  4361. return awsutil.Prettify(s)
  4362. }
  4363. // GoString returns the string representation
  4364. func (s GetLoggingOptionsInput) GoString() string {
  4365. return s.String()
  4366. }
  4367. // The output from the GetLoggingOptions operation.
  4368. type GetLoggingOptionsOutput struct {
  4369. _ struct{} `type:"structure"`
  4370. // The logging level.
  4371. LogLevel *string `locationName:"logLevel" type:"string" enum:"LogLevel"`
  4372. // The ARN of the IAM role that grants access.
  4373. RoleArn *string `locationName:"roleArn" type:"string"`
  4374. }
  4375. // String returns the string representation
  4376. func (s GetLoggingOptionsOutput) String() string {
  4377. return awsutil.Prettify(s)
  4378. }
  4379. // GoString returns the string representation
  4380. func (s GetLoggingOptionsOutput) GoString() string {
  4381. return s.String()
  4382. }
  4383. // The input for the GetPolicy operation.
  4384. type GetPolicyInput struct {
  4385. _ struct{} `type:"structure"`
  4386. // The name of the policy.
  4387. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  4388. }
  4389. // String returns the string representation
  4390. func (s GetPolicyInput) String() string {
  4391. return awsutil.Prettify(s)
  4392. }
  4393. // GoString returns the string representation
  4394. func (s GetPolicyInput) GoString() string {
  4395. return s.String()
  4396. }
  4397. // Validate inspects the fields of the type to determine if they are valid.
  4398. func (s *GetPolicyInput) Validate() error {
  4399. invalidParams := request.ErrInvalidParams{Context: "GetPolicyInput"}
  4400. if s.PolicyName == nil {
  4401. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  4402. }
  4403. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  4404. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  4405. }
  4406. if invalidParams.Len() > 0 {
  4407. return invalidParams
  4408. }
  4409. return nil
  4410. }
  4411. // The output from the GetPolicy operation.
  4412. type GetPolicyOutput struct {
  4413. _ struct{} `type:"structure"`
  4414. // The default policy version ID.
  4415. DefaultVersionId *string `locationName:"defaultVersionId" type:"string"`
  4416. // The policy ARN.
  4417. PolicyArn *string `locationName:"policyArn" type:"string"`
  4418. // The JSON document that describes the policy.
  4419. PolicyDocument *string `locationName:"policyDocument" type:"string"`
  4420. // The policy name.
  4421. PolicyName *string `locationName:"policyName" min:"1" type:"string"`
  4422. }
  4423. // String returns the string representation
  4424. func (s GetPolicyOutput) String() string {
  4425. return awsutil.Prettify(s)
  4426. }
  4427. // GoString returns the string representation
  4428. func (s GetPolicyOutput) GoString() string {
  4429. return s.String()
  4430. }
  4431. // The input for the GetPolicyVersion operation.
  4432. type GetPolicyVersionInput struct {
  4433. _ struct{} `type:"structure"`
  4434. // The name of the policy.
  4435. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  4436. // The policy version ID.
  4437. PolicyVersionId *string `location:"uri" locationName:"policyVersionId" type:"string" required:"true"`
  4438. }
  4439. // String returns the string representation
  4440. func (s GetPolicyVersionInput) String() string {
  4441. return awsutil.Prettify(s)
  4442. }
  4443. // GoString returns the string representation
  4444. func (s GetPolicyVersionInput) GoString() string {
  4445. return s.String()
  4446. }
  4447. // Validate inspects the fields of the type to determine if they are valid.
  4448. func (s *GetPolicyVersionInput) Validate() error {
  4449. invalidParams := request.ErrInvalidParams{Context: "GetPolicyVersionInput"}
  4450. if s.PolicyName == nil {
  4451. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  4452. }
  4453. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  4454. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  4455. }
  4456. if s.PolicyVersionId == nil {
  4457. invalidParams.Add(request.NewErrParamRequired("PolicyVersionId"))
  4458. }
  4459. if invalidParams.Len() > 0 {
  4460. return invalidParams
  4461. }
  4462. return nil
  4463. }
  4464. // The output from the GetPolicyVersion operation.
  4465. type GetPolicyVersionOutput struct {
  4466. _ struct{} `type:"structure"`
  4467. // Specifies whether the policy version is the default.
  4468. IsDefaultVersion *bool `locationName:"isDefaultVersion" type:"boolean"`
  4469. // The policy ARN.
  4470. PolicyArn *string `locationName:"policyArn" type:"string"`
  4471. // The JSON document that describes the policy.
  4472. PolicyDocument *string `locationName:"policyDocument" type:"string"`
  4473. // The policy name.
  4474. PolicyName *string `locationName:"policyName" min:"1" type:"string"`
  4475. // The policy version ID.
  4476. PolicyVersionId *string `locationName:"policyVersionId" type:"string"`
  4477. }
  4478. // String returns the string representation
  4479. func (s GetPolicyVersionOutput) String() string {
  4480. return awsutil.Prettify(s)
  4481. }
  4482. // GoString returns the string representation
  4483. func (s GetPolicyVersionOutput) GoString() string {
  4484. return s.String()
  4485. }
  4486. // The input to the GetRegistrationCode operation.
  4487. type GetRegistrationCodeInput struct {
  4488. _ struct{} `type:"structure"`
  4489. }
  4490. // String returns the string representation
  4491. func (s GetRegistrationCodeInput) String() string {
  4492. return awsutil.Prettify(s)
  4493. }
  4494. // GoString returns the string representation
  4495. func (s GetRegistrationCodeInput) GoString() string {
  4496. return s.String()
  4497. }
  4498. // The output from the GetRegistrationCode operation.
  4499. type GetRegistrationCodeOutput struct {
  4500. _ struct{} `type:"structure"`
  4501. // The CA certificate registration code.
  4502. RegistrationCode *string `locationName:"registrationCode" min:"64" type:"string"`
  4503. }
  4504. // String returns the string representation
  4505. func (s GetRegistrationCodeOutput) String() string {
  4506. return awsutil.Prettify(s)
  4507. }
  4508. // GoString returns the string representation
  4509. func (s GetRegistrationCodeOutput) GoString() string {
  4510. return s.String()
  4511. }
  4512. // The input for the GetTopicRule operation.
  4513. type GetTopicRuleInput struct {
  4514. _ struct{} `type:"structure"`
  4515. // The name of the rule.
  4516. RuleName *string `location:"uri" locationName:"ruleName" min:"1" type:"string" required:"true"`
  4517. }
  4518. // String returns the string representation
  4519. func (s GetTopicRuleInput) String() string {
  4520. return awsutil.Prettify(s)
  4521. }
  4522. // GoString returns the string representation
  4523. func (s GetTopicRuleInput) GoString() string {
  4524. return s.String()
  4525. }
  4526. // Validate inspects the fields of the type to determine if they are valid.
  4527. func (s *GetTopicRuleInput) Validate() error {
  4528. invalidParams := request.ErrInvalidParams{Context: "GetTopicRuleInput"}
  4529. if s.RuleName == nil {
  4530. invalidParams.Add(request.NewErrParamRequired("RuleName"))
  4531. }
  4532. if s.RuleName != nil && len(*s.RuleName) < 1 {
  4533. invalidParams.Add(request.NewErrParamMinLen("RuleName", 1))
  4534. }
  4535. if invalidParams.Len() > 0 {
  4536. return invalidParams
  4537. }
  4538. return nil
  4539. }
  4540. // The output from the GetTopicRule operation.
  4541. type GetTopicRuleOutput struct {
  4542. _ struct{} `type:"structure"`
  4543. // The rule.
  4544. Rule *TopicRule `locationName:"rule" type:"structure"`
  4545. // The rule ARN.
  4546. RuleArn *string `locationName:"ruleArn" type:"string"`
  4547. }
  4548. // String returns the string representation
  4549. func (s GetTopicRuleOutput) String() string {
  4550. return awsutil.Prettify(s)
  4551. }
  4552. // GoString returns the string representation
  4553. func (s GetTopicRuleOutput) GoString() string {
  4554. return s.String()
  4555. }
  4556. // Describes a key pair.
  4557. type KeyPair struct {
  4558. _ struct{} `type:"structure"`
  4559. // The private key.
  4560. PrivateKey *string `min:"1" type:"string"`
  4561. // The public key.
  4562. PublicKey *string `min:"1" type:"string"`
  4563. }
  4564. // String returns the string representation
  4565. func (s KeyPair) String() string {
  4566. return awsutil.Prettify(s)
  4567. }
  4568. // GoString returns the string representation
  4569. func (s KeyPair) GoString() string {
  4570. return s.String()
  4571. }
  4572. // Describes an action to write data to an Amazon Kinesis stream.
  4573. type KinesisAction struct {
  4574. _ struct{} `type:"structure"`
  4575. // The partition key.
  4576. PartitionKey *string `locationName:"partitionKey" type:"string"`
  4577. // The ARN of the IAM role that grants access to the Amazon Kinesis stream.
  4578. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  4579. // The name of the Amazon Kinesis stream.
  4580. StreamName *string `locationName:"streamName" type:"string" required:"true"`
  4581. }
  4582. // String returns the string representation
  4583. func (s KinesisAction) String() string {
  4584. return awsutil.Prettify(s)
  4585. }
  4586. // GoString returns the string representation
  4587. func (s KinesisAction) GoString() string {
  4588. return s.String()
  4589. }
  4590. // Validate inspects the fields of the type to determine if they are valid.
  4591. func (s *KinesisAction) Validate() error {
  4592. invalidParams := request.ErrInvalidParams{Context: "KinesisAction"}
  4593. if s.RoleArn == nil {
  4594. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  4595. }
  4596. if s.StreamName == nil {
  4597. invalidParams.Add(request.NewErrParamRequired("StreamName"))
  4598. }
  4599. if invalidParams.Len() > 0 {
  4600. return invalidParams
  4601. }
  4602. return nil
  4603. }
  4604. // Describes an action to invoke a Lambda function.
  4605. type LambdaAction struct {
  4606. _ struct{} `type:"structure"`
  4607. // The ARN of the Lambda function.
  4608. FunctionArn *string `locationName:"functionArn" type:"string" required:"true"`
  4609. }
  4610. // String returns the string representation
  4611. func (s LambdaAction) String() string {
  4612. return awsutil.Prettify(s)
  4613. }
  4614. // GoString returns the string representation
  4615. func (s LambdaAction) GoString() string {
  4616. return s.String()
  4617. }
  4618. // Validate inspects the fields of the type to determine if they are valid.
  4619. func (s *LambdaAction) Validate() error {
  4620. invalidParams := request.ErrInvalidParams{Context: "LambdaAction"}
  4621. if s.FunctionArn == nil {
  4622. invalidParams.Add(request.NewErrParamRequired("FunctionArn"))
  4623. }
  4624. if invalidParams.Len() > 0 {
  4625. return invalidParams
  4626. }
  4627. return nil
  4628. }
  4629. // Input for the ListCACertificates operation.
  4630. type ListCACertificatesInput struct {
  4631. _ struct{} `type:"structure"`
  4632. // Determines the order of the results.
  4633. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4634. // The marker for the next set of results.
  4635. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4636. // The result page size.
  4637. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4638. }
  4639. // String returns the string representation
  4640. func (s ListCACertificatesInput) String() string {
  4641. return awsutil.Prettify(s)
  4642. }
  4643. // GoString returns the string representation
  4644. func (s ListCACertificatesInput) GoString() string {
  4645. return s.String()
  4646. }
  4647. // Validate inspects the fields of the type to determine if they are valid.
  4648. func (s *ListCACertificatesInput) Validate() error {
  4649. invalidParams := request.ErrInvalidParams{Context: "ListCACertificatesInput"}
  4650. if s.PageSize != nil && *s.PageSize < 1 {
  4651. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4652. }
  4653. if invalidParams.Len() > 0 {
  4654. return invalidParams
  4655. }
  4656. return nil
  4657. }
  4658. // The output from the ListCACertificates operation.
  4659. type ListCACertificatesOutput struct {
  4660. _ struct{} `type:"structure"`
  4661. // The CA certificates registered in your AWS account.
  4662. Certificates []*CACertificate `locationName:"certificates" type:"list"`
  4663. // The current position within the list of CA certificates.
  4664. NextMarker *string `locationName:"nextMarker" type:"string"`
  4665. }
  4666. // String returns the string representation
  4667. func (s ListCACertificatesOutput) String() string {
  4668. return awsutil.Prettify(s)
  4669. }
  4670. // GoString returns the string representation
  4671. func (s ListCACertificatesOutput) GoString() string {
  4672. return s.String()
  4673. }
  4674. // The input to the ListCertificatesByCA operation.
  4675. type ListCertificatesByCAInput struct {
  4676. _ struct{} `type:"structure"`
  4677. // Specifies the order for results. If True, the results are returned in ascending
  4678. // order, based on the creation date.
  4679. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4680. // The ID of the CA certificate. This operation will list all registered device
  4681. // certificate that were signed by this CA certificate.
  4682. CaCertificateId *string `location:"uri" locationName:"caCertificateId" min:"64" type:"string" required:"true"`
  4683. // The marker for the next set of results.
  4684. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4685. // The result page size.
  4686. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4687. }
  4688. // String returns the string representation
  4689. func (s ListCertificatesByCAInput) String() string {
  4690. return awsutil.Prettify(s)
  4691. }
  4692. // GoString returns the string representation
  4693. func (s ListCertificatesByCAInput) GoString() string {
  4694. return s.String()
  4695. }
  4696. // Validate inspects the fields of the type to determine if they are valid.
  4697. func (s *ListCertificatesByCAInput) Validate() error {
  4698. invalidParams := request.ErrInvalidParams{Context: "ListCertificatesByCAInput"}
  4699. if s.CaCertificateId == nil {
  4700. invalidParams.Add(request.NewErrParamRequired("CaCertificateId"))
  4701. }
  4702. if s.CaCertificateId != nil && len(*s.CaCertificateId) < 64 {
  4703. invalidParams.Add(request.NewErrParamMinLen("CaCertificateId", 64))
  4704. }
  4705. if s.PageSize != nil && *s.PageSize < 1 {
  4706. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4707. }
  4708. if invalidParams.Len() > 0 {
  4709. return invalidParams
  4710. }
  4711. return nil
  4712. }
  4713. // The output of the ListCertificatesByCA operation.
  4714. type ListCertificatesByCAOutput struct {
  4715. _ struct{} `type:"structure"`
  4716. // The device certificates signed by the specified CA certificate.
  4717. Certificates []*Certificate `locationName:"certificates" type:"list"`
  4718. // The marker for the next set of results, or null if there are no additional
  4719. // results.
  4720. NextMarker *string `locationName:"nextMarker" type:"string"`
  4721. }
  4722. // String returns the string representation
  4723. func (s ListCertificatesByCAOutput) String() string {
  4724. return awsutil.Prettify(s)
  4725. }
  4726. // GoString returns the string representation
  4727. func (s ListCertificatesByCAOutput) GoString() string {
  4728. return s.String()
  4729. }
  4730. // The input for the ListCertificates operation.
  4731. type ListCertificatesInput struct {
  4732. _ struct{} `type:"structure"`
  4733. // Specifies the order for results. If True, the results are returned in ascending
  4734. // order, based on the creation date.
  4735. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4736. // The marker for the next set of results.
  4737. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4738. // The result page size.
  4739. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4740. }
  4741. // String returns the string representation
  4742. func (s ListCertificatesInput) String() string {
  4743. return awsutil.Prettify(s)
  4744. }
  4745. // GoString returns the string representation
  4746. func (s ListCertificatesInput) GoString() string {
  4747. return s.String()
  4748. }
  4749. // Validate inspects the fields of the type to determine if they are valid.
  4750. func (s *ListCertificatesInput) Validate() error {
  4751. invalidParams := request.ErrInvalidParams{Context: "ListCertificatesInput"}
  4752. if s.PageSize != nil && *s.PageSize < 1 {
  4753. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4754. }
  4755. if invalidParams.Len() > 0 {
  4756. return invalidParams
  4757. }
  4758. return nil
  4759. }
  4760. // The output of the ListCertificates operation.
  4761. type ListCertificatesOutput struct {
  4762. _ struct{} `type:"structure"`
  4763. // The descriptions of the certificates.
  4764. Certificates []*Certificate `locationName:"certificates" type:"list"`
  4765. // The marker for the next set of results, or null if there are no additional
  4766. // results.
  4767. NextMarker *string `locationName:"nextMarker" type:"string"`
  4768. }
  4769. // String returns the string representation
  4770. func (s ListCertificatesOutput) String() string {
  4771. return awsutil.Prettify(s)
  4772. }
  4773. // GoString returns the string representation
  4774. func (s ListCertificatesOutput) GoString() string {
  4775. return s.String()
  4776. }
  4777. // The input to the ListOutgoingCertificates operation.
  4778. type ListOutgoingCertificatesInput struct {
  4779. _ struct{} `type:"structure"`
  4780. // Specifies the order for results. If True, the results are returned in ascending
  4781. // order, based on the creation date.
  4782. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4783. // The marker for the next set of results.
  4784. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4785. // The result page size.
  4786. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4787. }
  4788. // String returns the string representation
  4789. func (s ListOutgoingCertificatesInput) String() string {
  4790. return awsutil.Prettify(s)
  4791. }
  4792. // GoString returns the string representation
  4793. func (s ListOutgoingCertificatesInput) GoString() string {
  4794. return s.String()
  4795. }
  4796. // Validate inspects the fields of the type to determine if they are valid.
  4797. func (s *ListOutgoingCertificatesInput) Validate() error {
  4798. invalidParams := request.ErrInvalidParams{Context: "ListOutgoingCertificatesInput"}
  4799. if s.PageSize != nil && *s.PageSize < 1 {
  4800. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4801. }
  4802. if invalidParams.Len() > 0 {
  4803. return invalidParams
  4804. }
  4805. return nil
  4806. }
  4807. // The output from the ListOutgoingCertificates operation.
  4808. type ListOutgoingCertificatesOutput struct {
  4809. _ struct{} `type:"structure"`
  4810. // The marker for the next set of results.
  4811. NextMarker *string `locationName:"nextMarker" type:"string"`
  4812. // The certificates that are being transfered but not yet accepted.
  4813. OutgoingCertificates []*OutgoingCertificate `locationName:"outgoingCertificates" type:"list"`
  4814. }
  4815. // String returns the string representation
  4816. func (s ListOutgoingCertificatesOutput) String() string {
  4817. return awsutil.Prettify(s)
  4818. }
  4819. // GoString returns the string representation
  4820. func (s ListOutgoingCertificatesOutput) GoString() string {
  4821. return s.String()
  4822. }
  4823. // The input for the ListPolicies operation.
  4824. type ListPoliciesInput struct {
  4825. _ struct{} `type:"structure"`
  4826. // Specifies the order for results. If true, the results are returned in ascending
  4827. // creation order.
  4828. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4829. // The marker for the next set of results.
  4830. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4831. // The result page size.
  4832. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4833. }
  4834. // String returns the string representation
  4835. func (s ListPoliciesInput) String() string {
  4836. return awsutil.Prettify(s)
  4837. }
  4838. // GoString returns the string representation
  4839. func (s ListPoliciesInput) GoString() string {
  4840. return s.String()
  4841. }
  4842. // Validate inspects the fields of the type to determine if they are valid.
  4843. func (s *ListPoliciesInput) Validate() error {
  4844. invalidParams := request.ErrInvalidParams{Context: "ListPoliciesInput"}
  4845. if s.PageSize != nil && *s.PageSize < 1 {
  4846. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4847. }
  4848. if invalidParams.Len() > 0 {
  4849. return invalidParams
  4850. }
  4851. return nil
  4852. }
  4853. // The output from the ListPolicies operation.
  4854. type ListPoliciesOutput struct {
  4855. _ struct{} `type:"structure"`
  4856. // The marker for the next set of results, or null if there are no additional
  4857. // results.
  4858. NextMarker *string `locationName:"nextMarker" type:"string"`
  4859. // The descriptions of the policies.
  4860. Policies []*Policy `locationName:"policies" type:"list"`
  4861. }
  4862. // String returns the string representation
  4863. func (s ListPoliciesOutput) String() string {
  4864. return awsutil.Prettify(s)
  4865. }
  4866. // GoString returns the string representation
  4867. func (s ListPoliciesOutput) GoString() string {
  4868. return s.String()
  4869. }
  4870. // The input for the ListPolicyPrincipals operation.
  4871. type ListPolicyPrincipalsInput struct {
  4872. _ struct{} `type:"structure"`
  4873. // Specifies the order for results. If true, the results are returned in ascending
  4874. // creation order.
  4875. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4876. // The marker for the next set of results.
  4877. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4878. // The result page size.
  4879. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4880. // The policy name.
  4881. PolicyName *string `location:"header" locationName:"x-amzn-iot-policy" min:"1" type:"string" required:"true"`
  4882. }
  4883. // String returns the string representation
  4884. func (s ListPolicyPrincipalsInput) String() string {
  4885. return awsutil.Prettify(s)
  4886. }
  4887. // GoString returns the string representation
  4888. func (s ListPolicyPrincipalsInput) GoString() string {
  4889. return s.String()
  4890. }
  4891. // Validate inspects the fields of the type to determine if they are valid.
  4892. func (s *ListPolicyPrincipalsInput) Validate() error {
  4893. invalidParams := request.ErrInvalidParams{Context: "ListPolicyPrincipalsInput"}
  4894. if s.PageSize != nil && *s.PageSize < 1 {
  4895. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4896. }
  4897. if s.PolicyName == nil {
  4898. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  4899. }
  4900. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  4901. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  4902. }
  4903. if invalidParams.Len() > 0 {
  4904. return invalidParams
  4905. }
  4906. return nil
  4907. }
  4908. // The output from the ListPolicyPrincipals operation.
  4909. type ListPolicyPrincipalsOutput struct {
  4910. _ struct{} `type:"structure"`
  4911. // The marker for the next set of results, or null if there are no additional
  4912. // results.
  4913. NextMarker *string `locationName:"nextMarker" type:"string"`
  4914. // The descriptions of the principals.
  4915. Principals []*string `locationName:"principals" type:"list"`
  4916. }
  4917. // String returns the string representation
  4918. func (s ListPolicyPrincipalsOutput) String() string {
  4919. return awsutil.Prettify(s)
  4920. }
  4921. // GoString returns the string representation
  4922. func (s ListPolicyPrincipalsOutput) GoString() string {
  4923. return s.String()
  4924. }
  4925. // The input for the ListPolicyVersions operation.
  4926. type ListPolicyVersionsInput struct {
  4927. _ struct{} `type:"structure"`
  4928. // The policy name.
  4929. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  4930. }
  4931. // String returns the string representation
  4932. func (s ListPolicyVersionsInput) String() string {
  4933. return awsutil.Prettify(s)
  4934. }
  4935. // GoString returns the string representation
  4936. func (s ListPolicyVersionsInput) GoString() string {
  4937. return s.String()
  4938. }
  4939. // Validate inspects the fields of the type to determine if they are valid.
  4940. func (s *ListPolicyVersionsInput) Validate() error {
  4941. invalidParams := request.ErrInvalidParams{Context: "ListPolicyVersionsInput"}
  4942. if s.PolicyName == nil {
  4943. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  4944. }
  4945. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  4946. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  4947. }
  4948. if invalidParams.Len() > 0 {
  4949. return invalidParams
  4950. }
  4951. return nil
  4952. }
  4953. // The output from the ListPolicyVersions operation.
  4954. type ListPolicyVersionsOutput struct {
  4955. _ struct{} `type:"structure"`
  4956. // The policy versions.
  4957. PolicyVersions []*PolicyVersion `locationName:"policyVersions" type:"list"`
  4958. }
  4959. // String returns the string representation
  4960. func (s ListPolicyVersionsOutput) String() string {
  4961. return awsutil.Prettify(s)
  4962. }
  4963. // GoString returns the string representation
  4964. func (s ListPolicyVersionsOutput) GoString() string {
  4965. return s.String()
  4966. }
  4967. // The input for the ListPrincipalPolicies operation.
  4968. type ListPrincipalPoliciesInput struct {
  4969. _ struct{} `type:"structure"`
  4970. // Specifies the order for results. If true, results are returned in ascending
  4971. // creation order.
  4972. AscendingOrder *bool `location:"querystring" locationName:"isAscendingOrder" type:"boolean"`
  4973. // The marker for the next set of results.
  4974. Marker *string `location:"querystring" locationName:"marker" type:"string"`
  4975. // The result page size.
  4976. PageSize *int64 `location:"querystring" locationName:"pageSize" min:"1" type:"integer"`
  4977. // The principal.
  4978. Principal *string `location:"header" locationName:"x-amzn-iot-principal" type:"string" required:"true"`
  4979. }
  4980. // String returns the string representation
  4981. func (s ListPrincipalPoliciesInput) String() string {
  4982. return awsutil.Prettify(s)
  4983. }
  4984. // GoString returns the string representation
  4985. func (s ListPrincipalPoliciesInput) GoString() string {
  4986. return s.String()
  4987. }
  4988. // Validate inspects the fields of the type to determine if they are valid.
  4989. func (s *ListPrincipalPoliciesInput) Validate() error {
  4990. invalidParams := request.ErrInvalidParams{Context: "ListPrincipalPoliciesInput"}
  4991. if s.PageSize != nil && *s.PageSize < 1 {
  4992. invalidParams.Add(request.NewErrParamMinValue("PageSize", 1))
  4993. }
  4994. if s.Principal == nil {
  4995. invalidParams.Add(request.NewErrParamRequired("Principal"))
  4996. }
  4997. if invalidParams.Len() > 0 {
  4998. return invalidParams
  4999. }
  5000. return nil
  5001. }
  5002. // The output from the ListPrincipalPolicies operation.
  5003. type ListPrincipalPoliciesOutput struct {
  5004. _ struct{} `type:"structure"`
  5005. // The marker for the next set of results, or null if there are no additional
  5006. // results.
  5007. NextMarker *string `locationName:"nextMarker" type:"string"`
  5008. // The policies.
  5009. Policies []*Policy `locationName:"policies" type:"list"`
  5010. }
  5011. // String returns the string representation
  5012. func (s ListPrincipalPoliciesOutput) String() string {
  5013. return awsutil.Prettify(s)
  5014. }
  5015. // GoString returns the string representation
  5016. func (s ListPrincipalPoliciesOutput) GoString() string {
  5017. return s.String()
  5018. }
  5019. // The input for the ListPrincipalThings operation.
  5020. type ListPrincipalThingsInput struct {
  5021. _ struct{} `type:"structure"`
  5022. // The maximum number of results to return in this operation.
  5023. MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"`
  5024. // The token for the next set of results, or null if there are no additional
  5025. // results.
  5026. NextToken *string `location:"querystring" locationName:"nextToken" type:"string"`
  5027. // The principal.
  5028. Principal *string `location:"header" locationName:"x-amzn-principal" type:"string" required:"true"`
  5029. }
  5030. // String returns the string representation
  5031. func (s ListPrincipalThingsInput) String() string {
  5032. return awsutil.Prettify(s)
  5033. }
  5034. // GoString returns the string representation
  5035. func (s ListPrincipalThingsInput) GoString() string {
  5036. return s.String()
  5037. }
  5038. // Validate inspects the fields of the type to determine if they are valid.
  5039. func (s *ListPrincipalThingsInput) Validate() error {
  5040. invalidParams := request.ErrInvalidParams{Context: "ListPrincipalThingsInput"}
  5041. if s.MaxResults != nil && *s.MaxResults < 1 {
  5042. invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
  5043. }
  5044. if s.Principal == nil {
  5045. invalidParams.Add(request.NewErrParamRequired("Principal"))
  5046. }
  5047. if invalidParams.Len() > 0 {
  5048. return invalidParams
  5049. }
  5050. return nil
  5051. }
  5052. // The output from the ListPrincipalThings operation.
  5053. type ListPrincipalThingsOutput struct {
  5054. _ struct{} `type:"structure"`
  5055. // The token for the next set of results, or null if there are no additional
  5056. // results.
  5057. NextToken *string `locationName:"nextToken" type:"string"`
  5058. // The things.
  5059. Things []*string `locationName:"things" type:"list"`
  5060. }
  5061. // String returns the string representation
  5062. func (s ListPrincipalThingsOutput) String() string {
  5063. return awsutil.Prettify(s)
  5064. }
  5065. // GoString returns the string representation
  5066. func (s ListPrincipalThingsOutput) GoString() string {
  5067. return s.String()
  5068. }
  5069. // The input for the ListThingPrincipal operation.
  5070. type ListThingPrincipalsInput struct {
  5071. _ struct{} `type:"structure"`
  5072. // The name of the thing.
  5073. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  5074. }
  5075. // String returns the string representation
  5076. func (s ListThingPrincipalsInput) String() string {
  5077. return awsutil.Prettify(s)
  5078. }
  5079. // GoString returns the string representation
  5080. func (s ListThingPrincipalsInput) GoString() string {
  5081. return s.String()
  5082. }
  5083. // Validate inspects the fields of the type to determine if they are valid.
  5084. func (s *ListThingPrincipalsInput) Validate() error {
  5085. invalidParams := request.ErrInvalidParams{Context: "ListThingPrincipalsInput"}
  5086. if s.ThingName == nil {
  5087. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  5088. }
  5089. if s.ThingName != nil && len(*s.ThingName) < 1 {
  5090. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  5091. }
  5092. if invalidParams.Len() > 0 {
  5093. return invalidParams
  5094. }
  5095. return nil
  5096. }
  5097. // The output from the ListThingPrincipals operation.
  5098. type ListThingPrincipalsOutput struct {
  5099. _ struct{} `type:"structure"`
  5100. // The principals associated with the thing.
  5101. Principals []*string `locationName:"principals" type:"list"`
  5102. }
  5103. // String returns the string representation
  5104. func (s ListThingPrincipalsOutput) String() string {
  5105. return awsutil.Prettify(s)
  5106. }
  5107. // GoString returns the string representation
  5108. func (s ListThingPrincipalsOutput) GoString() string {
  5109. return s.String()
  5110. }
  5111. // The input for the ListThingTypes operation.
  5112. type ListThingTypesInput struct {
  5113. _ struct{} `type:"structure"`
  5114. // The maximum number of results to return in this operation.
  5115. MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"`
  5116. // The token for the next set of results, or null if there are no additional
  5117. // results.
  5118. NextToken *string `location:"querystring" locationName:"nextToken" type:"string"`
  5119. // The name of the thing type.
  5120. ThingTypeName *string `location:"querystring" locationName:"thingTypeName" min:"1" type:"string"`
  5121. }
  5122. // String returns the string representation
  5123. func (s ListThingTypesInput) String() string {
  5124. return awsutil.Prettify(s)
  5125. }
  5126. // GoString returns the string representation
  5127. func (s ListThingTypesInput) GoString() string {
  5128. return s.String()
  5129. }
  5130. // Validate inspects the fields of the type to determine if they are valid.
  5131. func (s *ListThingTypesInput) Validate() error {
  5132. invalidParams := request.ErrInvalidParams{Context: "ListThingTypesInput"}
  5133. if s.MaxResults != nil && *s.MaxResults < 1 {
  5134. invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
  5135. }
  5136. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  5137. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  5138. }
  5139. if invalidParams.Len() > 0 {
  5140. return invalidParams
  5141. }
  5142. return nil
  5143. }
  5144. // The output for the ListThingTypes operation.
  5145. type ListThingTypesOutput struct {
  5146. _ struct{} `type:"structure"`
  5147. // The token for the next set of results, or null if there are no additional
  5148. // results.
  5149. NextToken *string `locationName:"nextToken" type:"string"`
  5150. // The thing types.
  5151. ThingTypes []*ThingTypeDefinition `locationName:"thingTypes" type:"list"`
  5152. }
  5153. // String returns the string representation
  5154. func (s ListThingTypesOutput) String() string {
  5155. return awsutil.Prettify(s)
  5156. }
  5157. // GoString returns the string representation
  5158. func (s ListThingTypesOutput) GoString() string {
  5159. return s.String()
  5160. }
  5161. // The input for the ListThings operation.
  5162. type ListThingsInput struct {
  5163. _ struct{} `type:"structure"`
  5164. // The attribute name used to search for things.
  5165. AttributeName *string `location:"querystring" locationName:"attributeName" type:"string"`
  5166. // The attribute value used to search for things.
  5167. AttributeValue *string `location:"querystring" locationName:"attributeValue" type:"string"`
  5168. // The maximum number of results to return in this operation.
  5169. MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"`
  5170. // The token for the next set of results, or null if there are no additional
  5171. // results.
  5172. NextToken *string `location:"querystring" locationName:"nextToken" type:"string"`
  5173. // The name of the thing type used to search for things.
  5174. ThingTypeName *string `location:"querystring" locationName:"thingTypeName" min:"1" type:"string"`
  5175. }
  5176. // String returns the string representation
  5177. func (s ListThingsInput) String() string {
  5178. return awsutil.Prettify(s)
  5179. }
  5180. // GoString returns the string representation
  5181. func (s ListThingsInput) GoString() string {
  5182. return s.String()
  5183. }
  5184. // Validate inspects the fields of the type to determine if they are valid.
  5185. func (s *ListThingsInput) Validate() error {
  5186. invalidParams := request.ErrInvalidParams{Context: "ListThingsInput"}
  5187. if s.MaxResults != nil && *s.MaxResults < 1 {
  5188. invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
  5189. }
  5190. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  5191. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  5192. }
  5193. if invalidParams.Len() > 0 {
  5194. return invalidParams
  5195. }
  5196. return nil
  5197. }
  5198. // The output from the ListThings operation.
  5199. type ListThingsOutput struct {
  5200. _ struct{} `type:"structure"`
  5201. // The token for the next set of results, or null if there are no additional
  5202. // results.
  5203. NextToken *string `locationName:"nextToken" type:"string"`
  5204. // The things.
  5205. Things []*ThingAttribute `locationName:"things" type:"list"`
  5206. }
  5207. // String returns the string representation
  5208. func (s ListThingsOutput) String() string {
  5209. return awsutil.Prettify(s)
  5210. }
  5211. // GoString returns the string representation
  5212. func (s ListThingsOutput) GoString() string {
  5213. return s.String()
  5214. }
  5215. // The input for the ListTopicRules operation.
  5216. type ListTopicRulesInput struct {
  5217. _ struct{} `type:"structure"`
  5218. // The maximum number of results to return.
  5219. MaxResults *int64 `location:"querystring" locationName:"maxResults" min:"1" type:"integer"`
  5220. // A token used to retrieve the next value.
  5221. NextToken *string `location:"querystring" locationName:"nextToken" type:"string"`
  5222. // Specifies whether the rule is disabled.
  5223. RuleDisabled *bool `location:"querystring" locationName:"ruleDisabled" type:"boolean"`
  5224. // The topic.
  5225. Topic *string `location:"querystring" locationName:"topic" type:"string"`
  5226. }
  5227. // String returns the string representation
  5228. func (s ListTopicRulesInput) String() string {
  5229. return awsutil.Prettify(s)
  5230. }
  5231. // GoString returns the string representation
  5232. func (s ListTopicRulesInput) GoString() string {
  5233. return s.String()
  5234. }
  5235. // Validate inspects the fields of the type to determine if they are valid.
  5236. func (s *ListTopicRulesInput) Validate() error {
  5237. invalidParams := request.ErrInvalidParams{Context: "ListTopicRulesInput"}
  5238. if s.MaxResults != nil && *s.MaxResults < 1 {
  5239. invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1))
  5240. }
  5241. if invalidParams.Len() > 0 {
  5242. return invalidParams
  5243. }
  5244. return nil
  5245. }
  5246. // The output from the ListTopicRules operation.
  5247. type ListTopicRulesOutput struct {
  5248. _ struct{} `type:"structure"`
  5249. // A token used to retrieve the next value.
  5250. NextToken *string `locationName:"nextToken" type:"string"`
  5251. // The rules.
  5252. Rules []*TopicRuleListItem `locationName:"rules" type:"list"`
  5253. }
  5254. // String returns the string representation
  5255. func (s ListTopicRulesOutput) String() string {
  5256. return awsutil.Prettify(s)
  5257. }
  5258. // GoString returns the string representation
  5259. func (s ListTopicRulesOutput) GoString() string {
  5260. return s.String()
  5261. }
  5262. // Describes the logging options payload.
  5263. type LoggingOptionsPayload struct {
  5264. _ struct{} `type:"structure"`
  5265. // The logging level.
  5266. LogLevel *string `locationName:"logLevel" type:"string" enum:"LogLevel"`
  5267. // The ARN of the IAM role that grants access.
  5268. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  5269. }
  5270. // String returns the string representation
  5271. func (s LoggingOptionsPayload) String() string {
  5272. return awsutil.Prettify(s)
  5273. }
  5274. // GoString returns the string representation
  5275. func (s LoggingOptionsPayload) GoString() string {
  5276. return s.String()
  5277. }
  5278. // Validate inspects the fields of the type to determine if they are valid.
  5279. func (s *LoggingOptionsPayload) Validate() error {
  5280. invalidParams := request.ErrInvalidParams{Context: "LoggingOptionsPayload"}
  5281. if s.RoleArn == nil {
  5282. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  5283. }
  5284. if invalidParams.Len() > 0 {
  5285. return invalidParams
  5286. }
  5287. return nil
  5288. }
  5289. // A certificate that has been transfered but not yet accepted.
  5290. type OutgoingCertificate struct {
  5291. _ struct{} `type:"structure"`
  5292. // The certificate ARN.
  5293. CertificateArn *string `locationName:"certificateArn" type:"string"`
  5294. // The certificate ID.
  5295. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  5296. // The certificate creation date.
  5297. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"`
  5298. // The date the transfer was initiated.
  5299. TransferDate *time.Time `locationName:"transferDate" type:"timestamp" timestampFormat:"unix"`
  5300. // The transfer message.
  5301. TransferMessage *string `locationName:"transferMessage" type:"string"`
  5302. // The AWS account to which the transfer was made.
  5303. TransferredTo *string `locationName:"transferredTo" type:"string"`
  5304. }
  5305. // String returns the string representation
  5306. func (s OutgoingCertificate) String() string {
  5307. return awsutil.Prettify(s)
  5308. }
  5309. // GoString returns the string representation
  5310. func (s OutgoingCertificate) GoString() string {
  5311. return s.String()
  5312. }
  5313. // Describes an AWS IoT policy.
  5314. type Policy struct {
  5315. _ struct{} `type:"structure"`
  5316. // The policy ARN.
  5317. PolicyArn *string `locationName:"policyArn" type:"string"`
  5318. // The policy name.
  5319. PolicyName *string `locationName:"policyName" min:"1" type:"string"`
  5320. }
  5321. // String returns the string representation
  5322. func (s Policy) String() string {
  5323. return awsutil.Prettify(s)
  5324. }
  5325. // GoString returns the string representation
  5326. func (s Policy) GoString() string {
  5327. return s.String()
  5328. }
  5329. // Describes a policy version.
  5330. type PolicyVersion struct {
  5331. _ struct{} `type:"structure"`
  5332. // The date and time the policy was created.
  5333. CreateDate *time.Time `locationName:"createDate" type:"timestamp" timestampFormat:"unix"`
  5334. // Specifies whether the policy version is the default.
  5335. IsDefaultVersion *bool `locationName:"isDefaultVersion" type:"boolean"`
  5336. // The policy version ID.
  5337. VersionId *string `locationName:"versionId" type:"string"`
  5338. }
  5339. // String returns the string representation
  5340. func (s PolicyVersion) String() string {
  5341. return awsutil.Prettify(s)
  5342. }
  5343. // GoString returns the string representation
  5344. func (s PolicyVersion) GoString() string {
  5345. return s.String()
  5346. }
  5347. // The input to the RegisterCACertificate operation.
  5348. type RegisterCACertificateInput struct {
  5349. _ struct{} `type:"structure"`
  5350. // Allows this CA certificate to be used for auto registration of device certificates.
  5351. AllowAutoRegistration *bool `location:"querystring" locationName:"allowAutoRegistration" type:"boolean"`
  5352. // The CA certificate.
  5353. CaCertificate *string `locationName:"caCertificate" min:"1" type:"string" required:"true"`
  5354. // A boolean value that specifies if the CA certificate is set to active.
  5355. SetAsActive *bool `location:"querystring" locationName:"setAsActive" type:"boolean"`
  5356. // The private key verification certificate.
  5357. VerificationCertificate *string `locationName:"verificationCertificate" min:"1" type:"string" required:"true"`
  5358. }
  5359. // String returns the string representation
  5360. func (s RegisterCACertificateInput) String() string {
  5361. return awsutil.Prettify(s)
  5362. }
  5363. // GoString returns the string representation
  5364. func (s RegisterCACertificateInput) GoString() string {
  5365. return s.String()
  5366. }
  5367. // Validate inspects the fields of the type to determine if they are valid.
  5368. func (s *RegisterCACertificateInput) Validate() error {
  5369. invalidParams := request.ErrInvalidParams{Context: "RegisterCACertificateInput"}
  5370. if s.CaCertificate == nil {
  5371. invalidParams.Add(request.NewErrParamRequired("CaCertificate"))
  5372. }
  5373. if s.CaCertificate != nil && len(*s.CaCertificate) < 1 {
  5374. invalidParams.Add(request.NewErrParamMinLen("CaCertificate", 1))
  5375. }
  5376. if s.VerificationCertificate == nil {
  5377. invalidParams.Add(request.NewErrParamRequired("VerificationCertificate"))
  5378. }
  5379. if s.VerificationCertificate != nil && len(*s.VerificationCertificate) < 1 {
  5380. invalidParams.Add(request.NewErrParamMinLen("VerificationCertificate", 1))
  5381. }
  5382. if invalidParams.Len() > 0 {
  5383. return invalidParams
  5384. }
  5385. return nil
  5386. }
  5387. // The output from the RegisterCACertificateResponse operation.
  5388. type RegisterCACertificateOutput struct {
  5389. _ struct{} `type:"structure"`
  5390. // The CA certificate ARN.
  5391. CertificateArn *string `locationName:"certificateArn" type:"string"`
  5392. // The CA certificate identifier.
  5393. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  5394. }
  5395. // String returns the string representation
  5396. func (s RegisterCACertificateOutput) String() string {
  5397. return awsutil.Prettify(s)
  5398. }
  5399. // GoString returns the string representation
  5400. func (s RegisterCACertificateOutput) GoString() string {
  5401. return s.String()
  5402. }
  5403. // The input to the RegisterCertificate operation.
  5404. type RegisterCertificateInput struct {
  5405. _ struct{} `type:"structure"`
  5406. // The CA certificate used to sign the device certificate being registered.
  5407. CaCertificatePem *string `locationName:"caCertificatePem" min:"1" type:"string"`
  5408. // The certificate data, in PEM format.
  5409. CertificatePem *string `locationName:"certificatePem" min:"1" type:"string" required:"true"`
  5410. // A boolean value that specifies if the CA certificate is set to active.
  5411. SetAsActive *bool `location:"querystring" locationName:"setAsActive" type:"boolean"`
  5412. }
  5413. // String returns the string representation
  5414. func (s RegisterCertificateInput) String() string {
  5415. return awsutil.Prettify(s)
  5416. }
  5417. // GoString returns the string representation
  5418. func (s RegisterCertificateInput) GoString() string {
  5419. return s.String()
  5420. }
  5421. // Validate inspects the fields of the type to determine if they are valid.
  5422. func (s *RegisterCertificateInput) Validate() error {
  5423. invalidParams := request.ErrInvalidParams{Context: "RegisterCertificateInput"}
  5424. if s.CaCertificatePem != nil && len(*s.CaCertificatePem) < 1 {
  5425. invalidParams.Add(request.NewErrParamMinLen("CaCertificatePem", 1))
  5426. }
  5427. if s.CertificatePem == nil {
  5428. invalidParams.Add(request.NewErrParamRequired("CertificatePem"))
  5429. }
  5430. if s.CertificatePem != nil && len(*s.CertificatePem) < 1 {
  5431. invalidParams.Add(request.NewErrParamMinLen("CertificatePem", 1))
  5432. }
  5433. if invalidParams.Len() > 0 {
  5434. return invalidParams
  5435. }
  5436. return nil
  5437. }
  5438. // The output from the RegisterCertificate operation.
  5439. type RegisterCertificateOutput struct {
  5440. _ struct{} `type:"structure"`
  5441. // The certificate ARN.
  5442. CertificateArn *string `locationName:"certificateArn" type:"string"`
  5443. // The certificate identifier.
  5444. CertificateId *string `locationName:"certificateId" min:"64" type:"string"`
  5445. }
  5446. // String returns the string representation
  5447. func (s RegisterCertificateOutput) String() string {
  5448. return awsutil.Prettify(s)
  5449. }
  5450. // GoString returns the string representation
  5451. func (s RegisterCertificateOutput) GoString() string {
  5452. return s.String()
  5453. }
  5454. // The input for the RejectCertificateTransfer operation.
  5455. type RejectCertificateTransferInput struct {
  5456. _ struct{} `type:"structure"`
  5457. // The ID of the certificate.
  5458. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  5459. // The reason the certificate transfer was rejected.
  5460. RejectReason *string `locationName:"rejectReason" type:"string"`
  5461. }
  5462. // String returns the string representation
  5463. func (s RejectCertificateTransferInput) String() string {
  5464. return awsutil.Prettify(s)
  5465. }
  5466. // GoString returns the string representation
  5467. func (s RejectCertificateTransferInput) GoString() string {
  5468. return s.String()
  5469. }
  5470. // Validate inspects the fields of the type to determine if they are valid.
  5471. func (s *RejectCertificateTransferInput) Validate() error {
  5472. invalidParams := request.ErrInvalidParams{Context: "RejectCertificateTransferInput"}
  5473. if s.CertificateId == nil {
  5474. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  5475. }
  5476. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  5477. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  5478. }
  5479. if invalidParams.Len() > 0 {
  5480. return invalidParams
  5481. }
  5482. return nil
  5483. }
  5484. type RejectCertificateTransferOutput struct {
  5485. _ struct{} `type:"structure"`
  5486. }
  5487. // String returns the string representation
  5488. func (s RejectCertificateTransferOutput) String() string {
  5489. return awsutil.Prettify(s)
  5490. }
  5491. // GoString returns the string representation
  5492. func (s RejectCertificateTransferOutput) GoString() string {
  5493. return s.String()
  5494. }
  5495. // The input for the ReplaceTopicRule operation.
  5496. type ReplaceTopicRuleInput struct {
  5497. _ struct{} `type:"structure" payload:"TopicRulePayload"`
  5498. // The name of the rule.
  5499. RuleName *string `location:"uri" locationName:"ruleName" min:"1" type:"string" required:"true"`
  5500. // The rule payload.
  5501. TopicRulePayload *TopicRulePayload `locationName:"topicRulePayload" type:"structure" required:"true"`
  5502. }
  5503. // String returns the string representation
  5504. func (s ReplaceTopicRuleInput) String() string {
  5505. return awsutil.Prettify(s)
  5506. }
  5507. // GoString returns the string representation
  5508. func (s ReplaceTopicRuleInput) GoString() string {
  5509. return s.String()
  5510. }
  5511. // Validate inspects the fields of the type to determine if they are valid.
  5512. func (s *ReplaceTopicRuleInput) Validate() error {
  5513. invalidParams := request.ErrInvalidParams{Context: "ReplaceTopicRuleInput"}
  5514. if s.RuleName == nil {
  5515. invalidParams.Add(request.NewErrParamRequired("RuleName"))
  5516. }
  5517. if s.RuleName != nil && len(*s.RuleName) < 1 {
  5518. invalidParams.Add(request.NewErrParamMinLen("RuleName", 1))
  5519. }
  5520. if s.TopicRulePayload == nil {
  5521. invalidParams.Add(request.NewErrParamRequired("TopicRulePayload"))
  5522. }
  5523. if s.TopicRulePayload != nil {
  5524. if err := s.TopicRulePayload.Validate(); err != nil {
  5525. invalidParams.AddNested("TopicRulePayload", err.(request.ErrInvalidParams))
  5526. }
  5527. }
  5528. if invalidParams.Len() > 0 {
  5529. return invalidParams
  5530. }
  5531. return nil
  5532. }
  5533. type ReplaceTopicRuleOutput struct {
  5534. _ struct{} `type:"structure"`
  5535. }
  5536. // String returns the string representation
  5537. func (s ReplaceTopicRuleOutput) String() string {
  5538. return awsutil.Prettify(s)
  5539. }
  5540. // GoString returns the string representation
  5541. func (s ReplaceTopicRuleOutput) GoString() string {
  5542. return s.String()
  5543. }
  5544. // Describes an action to republish to another topic.
  5545. type RepublishAction struct {
  5546. _ struct{} `type:"structure"`
  5547. // The ARN of the IAM role that grants access.
  5548. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  5549. // The name of the MQTT topic.
  5550. Topic *string `locationName:"topic" type:"string" required:"true"`
  5551. }
  5552. // String returns the string representation
  5553. func (s RepublishAction) String() string {
  5554. return awsutil.Prettify(s)
  5555. }
  5556. // GoString returns the string representation
  5557. func (s RepublishAction) GoString() string {
  5558. return s.String()
  5559. }
  5560. // Validate inspects the fields of the type to determine if they are valid.
  5561. func (s *RepublishAction) Validate() error {
  5562. invalidParams := request.ErrInvalidParams{Context: "RepublishAction"}
  5563. if s.RoleArn == nil {
  5564. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  5565. }
  5566. if s.Topic == nil {
  5567. invalidParams.Add(request.NewErrParamRequired("Topic"))
  5568. }
  5569. if invalidParams.Len() > 0 {
  5570. return invalidParams
  5571. }
  5572. return nil
  5573. }
  5574. // Describes an action to write data to an Amazon S3 bucket.
  5575. type S3Action struct {
  5576. _ struct{} `type:"structure"`
  5577. // The Amazon S3 bucket.
  5578. BucketName *string `locationName:"bucketName" type:"string" required:"true"`
  5579. // The object key.
  5580. Key *string `locationName:"key" type:"string" required:"true"`
  5581. // The ARN of the IAM role that grants access.
  5582. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  5583. }
  5584. // String returns the string representation
  5585. func (s S3Action) String() string {
  5586. return awsutil.Prettify(s)
  5587. }
  5588. // GoString returns the string representation
  5589. func (s S3Action) GoString() string {
  5590. return s.String()
  5591. }
  5592. // Validate inspects the fields of the type to determine if they are valid.
  5593. func (s *S3Action) Validate() error {
  5594. invalidParams := request.ErrInvalidParams{Context: "S3Action"}
  5595. if s.BucketName == nil {
  5596. invalidParams.Add(request.NewErrParamRequired("BucketName"))
  5597. }
  5598. if s.Key == nil {
  5599. invalidParams.Add(request.NewErrParamRequired("Key"))
  5600. }
  5601. if s.RoleArn == nil {
  5602. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  5603. }
  5604. if invalidParams.Len() > 0 {
  5605. return invalidParams
  5606. }
  5607. return nil
  5608. }
  5609. // The input for the SetDefaultPolicyVersion operation.
  5610. type SetDefaultPolicyVersionInput struct {
  5611. _ struct{} `type:"structure"`
  5612. // The policy name.
  5613. PolicyName *string `location:"uri" locationName:"policyName" min:"1" type:"string" required:"true"`
  5614. // The policy version ID.
  5615. PolicyVersionId *string `location:"uri" locationName:"policyVersionId" type:"string" required:"true"`
  5616. }
  5617. // String returns the string representation
  5618. func (s SetDefaultPolicyVersionInput) String() string {
  5619. return awsutil.Prettify(s)
  5620. }
  5621. // GoString returns the string representation
  5622. func (s SetDefaultPolicyVersionInput) GoString() string {
  5623. return s.String()
  5624. }
  5625. // Validate inspects the fields of the type to determine if they are valid.
  5626. func (s *SetDefaultPolicyVersionInput) Validate() error {
  5627. invalidParams := request.ErrInvalidParams{Context: "SetDefaultPolicyVersionInput"}
  5628. if s.PolicyName == nil {
  5629. invalidParams.Add(request.NewErrParamRequired("PolicyName"))
  5630. }
  5631. if s.PolicyName != nil && len(*s.PolicyName) < 1 {
  5632. invalidParams.Add(request.NewErrParamMinLen("PolicyName", 1))
  5633. }
  5634. if s.PolicyVersionId == nil {
  5635. invalidParams.Add(request.NewErrParamRequired("PolicyVersionId"))
  5636. }
  5637. if invalidParams.Len() > 0 {
  5638. return invalidParams
  5639. }
  5640. return nil
  5641. }
  5642. type SetDefaultPolicyVersionOutput struct {
  5643. _ struct{} `type:"structure"`
  5644. }
  5645. // String returns the string representation
  5646. func (s SetDefaultPolicyVersionOutput) String() string {
  5647. return awsutil.Prettify(s)
  5648. }
  5649. // GoString returns the string representation
  5650. func (s SetDefaultPolicyVersionOutput) GoString() string {
  5651. return s.String()
  5652. }
  5653. // The input for the SetLoggingOptions operation.
  5654. type SetLoggingOptionsInput struct {
  5655. _ struct{} `type:"structure" payload:"LoggingOptionsPayload"`
  5656. // The logging options payload.
  5657. LoggingOptionsPayload *LoggingOptionsPayload `locationName:"loggingOptionsPayload" type:"structure" required:"true"`
  5658. }
  5659. // String returns the string representation
  5660. func (s SetLoggingOptionsInput) String() string {
  5661. return awsutil.Prettify(s)
  5662. }
  5663. // GoString returns the string representation
  5664. func (s SetLoggingOptionsInput) GoString() string {
  5665. return s.String()
  5666. }
  5667. // Validate inspects the fields of the type to determine if they are valid.
  5668. func (s *SetLoggingOptionsInput) Validate() error {
  5669. invalidParams := request.ErrInvalidParams{Context: "SetLoggingOptionsInput"}
  5670. if s.LoggingOptionsPayload == nil {
  5671. invalidParams.Add(request.NewErrParamRequired("LoggingOptionsPayload"))
  5672. }
  5673. if s.LoggingOptionsPayload != nil {
  5674. if err := s.LoggingOptionsPayload.Validate(); err != nil {
  5675. invalidParams.AddNested("LoggingOptionsPayload", err.(request.ErrInvalidParams))
  5676. }
  5677. }
  5678. if invalidParams.Len() > 0 {
  5679. return invalidParams
  5680. }
  5681. return nil
  5682. }
  5683. type SetLoggingOptionsOutput struct {
  5684. _ struct{} `type:"structure"`
  5685. }
  5686. // String returns the string representation
  5687. func (s SetLoggingOptionsOutput) String() string {
  5688. return awsutil.Prettify(s)
  5689. }
  5690. // GoString returns the string representation
  5691. func (s SetLoggingOptionsOutput) GoString() string {
  5692. return s.String()
  5693. }
  5694. // Describes an action to publish to an Amazon SNS topic.
  5695. type SnsAction struct {
  5696. _ struct{} `type:"structure"`
  5697. // The message format of the message to publish. Optional. Accepted values are
  5698. // "JSON" and "RAW". The default value of the attribute is "RAW". SNS uses this
  5699. // setting to determine if the payload should be parsed and relevant platform-specific
  5700. // bits of the payload should be extracted. To read more about SNS message formats,
  5701. // see refer to their official documentation.
  5702. MessageFormat *string `locationName:"messageFormat" type:"string" enum:"MessageFormat"`
  5703. // The ARN of the IAM role that grants access.
  5704. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  5705. // The ARN of the SNS topic.
  5706. TargetArn *string `locationName:"targetArn" type:"string" required:"true"`
  5707. }
  5708. // String returns the string representation
  5709. func (s SnsAction) String() string {
  5710. return awsutil.Prettify(s)
  5711. }
  5712. // GoString returns the string representation
  5713. func (s SnsAction) GoString() string {
  5714. return s.String()
  5715. }
  5716. // Validate inspects the fields of the type to determine if they are valid.
  5717. func (s *SnsAction) Validate() error {
  5718. invalidParams := request.ErrInvalidParams{Context: "SnsAction"}
  5719. if s.RoleArn == nil {
  5720. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  5721. }
  5722. if s.TargetArn == nil {
  5723. invalidParams.Add(request.NewErrParamRequired("TargetArn"))
  5724. }
  5725. if invalidParams.Len() > 0 {
  5726. return invalidParams
  5727. }
  5728. return nil
  5729. }
  5730. // Describes an action to publish data to an Amazon SQS queue.
  5731. type SqsAction struct {
  5732. _ struct{} `type:"structure"`
  5733. // The URL of the Amazon SQS queue.
  5734. QueueUrl *string `locationName:"queueUrl" type:"string" required:"true"`
  5735. // The ARN of the IAM role that grants access.
  5736. RoleArn *string `locationName:"roleArn" type:"string" required:"true"`
  5737. // Specifies whether to use Base64 encoding.
  5738. UseBase64 *bool `locationName:"useBase64" type:"boolean"`
  5739. }
  5740. // String returns the string representation
  5741. func (s SqsAction) String() string {
  5742. return awsutil.Prettify(s)
  5743. }
  5744. // GoString returns the string representation
  5745. func (s SqsAction) GoString() string {
  5746. return s.String()
  5747. }
  5748. // Validate inspects the fields of the type to determine if they are valid.
  5749. func (s *SqsAction) Validate() error {
  5750. invalidParams := request.ErrInvalidParams{Context: "SqsAction"}
  5751. if s.QueueUrl == nil {
  5752. invalidParams.Add(request.NewErrParamRequired("QueueUrl"))
  5753. }
  5754. if s.RoleArn == nil {
  5755. invalidParams.Add(request.NewErrParamRequired("RoleArn"))
  5756. }
  5757. if invalidParams.Len() > 0 {
  5758. return invalidParams
  5759. }
  5760. return nil
  5761. }
  5762. // The properties of the thing, including thing name, thing type name, and a
  5763. // list of thing attributes.
  5764. type ThingAttribute struct {
  5765. _ struct{} `type:"structure"`
  5766. // A list of thing attributes which are name-value pairs.
  5767. Attributes map[string]*string `locationName:"attributes" type:"map"`
  5768. // The name of the thing.
  5769. ThingName *string `locationName:"thingName" min:"1" type:"string"`
  5770. // The name of the thing type, if the thing has been associated with a type.
  5771. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  5772. // The version of the thing record in the registry.
  5773. Version *int64 `locationName:"version" type:"long"`
  5774. }
  5775. // String returns the string representation
  5776. func (s ThingAttribute) String() string {
  5777. return awsutil.Prettify(s)
  5778. }
  5779. // GoString returns the string representation
  5780. func (s ThingAttribute) GoString() string {
  5781. return s.String()
  5782. }
  5783. // The definition of the thing type, including thing type name and description.
  5784. type ThingTypeDefinition struct {
  5785. _ struct{} `type:"structure"`
  5786. // The ThingTypeMetadata contains additional information about the thing type
  5787. // including: creation date and time, a value indicating whether the thing type
  5788. // is deprecated, and a date and time when time was deprecated.
  5789. ThingTypeMetadata *ThingTypeMetadata `locationName:"thingTypeMetadata" type:"structure"`
  5790. // The name of the thing type.
  5791. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  5792. // The ThingTypeProperties for the thing type.
  5793. ThingTypeProperties *ThingTypeProperties `locationName:"thingTypeProperties" type:"structure"`
  5794. }
  5795. // String returns the string representation
  5796. func (s ThingTypeDefinition) String() string {
  5797. return awsutil.Prettify(s)
  5798. }
  5799. // GoString returns the string representation
  5800. func (s ThingTypeDefinition) GoString() string {
  5801. return s.String()
  5802. }
  5803. // The ThingTypeMetadata contains additional information about the thing type
  5804. // including: creation date and time, a value indicating whether the thing type
  5805. // is deprecated, and a date and time when time was deprecated.
  5806. type ThingTypeMetadata struct {
  5807. _ struct{} `type:"structure"`
  5808. // The date and time when the thing type was created.
  5809. CreationDate *time.Time `locationName:"creationDate" type:"timestamp" timestampFormat:"unix"`
  5810. // Whether the thing type is deprecated. If true, no new things could be associated
  5811. // with this type.
  5812. Deprecated *bool `locationName:"deprecated" type:"boolean"`
  5813. // The date and time when the thing type was deprecated.
  5814. DeprecationDate *time.Time `locationName:"deprecationDate" type:"timestamp" timestampFormat:"unix"`
  5815. }
  5816. // String returns the string representation
  5817. func (s ThingTypeMetadata) String() string {
  5818. return awsutil.Prettify(s)
  5819. }
  5820. // GoString returns the string representation
  5821. func (s ThingTypeMetadata) GoString() string {
  5822. return s.String()
  5823. }
  5824. // The ThingTypeProperties contains information about the thing type including:
  5825. // a thing type description, and a list of searchable thing attribute names.
  5826. type ThingTypeProperties struct {
  5827. _ struct{} `type:"structure"`
  5828. // A list of searchable thing attribute names.
  5829. SearchableAttributes []*string `locationName:"searchableAttributes" type:"list"`
  5830. // The description of the thing type.
  5831. ThingTypeDescription *string `locationName:"thingTypeDescription" type:"string"`
  5832. }
  5833. // String returns the string representation
  5834. func (s ThingTypeProperties) String() string {
  5835. return awsutil.Prettify(s)
  5836. }
  5837. // GoString returns the string representation
  5838. func (s ThingTypeProperties) GoString() string {
  5839. return s.String()
  5840. }
  5841. // Describes a rule.
  5842. type TopicRule struct {
  5843. _ struct{} `type:"structure"`
  5844. // The actions associated with the rule.
  5845. Actions []*Action `locationName:"actions" type:"list"`
  5846. // The version of the SQL rules engine to use when evaluating the rule.
  5847. AwsIotSqlVersion *string `locationName:"awsIotSqlVersion" type:"string"`
  5848. // The date and time the rule was created.
  5849. CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"unix"`
  5850. // The description of the rule.
  5851. Description *string `locationName:"description" type:"string"`
  5852. // Specifies whether the rule is disabled.
  5853. RuleDisabled *bool `locationName:"ruleDisabled" type:"boolean"`
  5854. // The name of the rule.
  5855. RuleName *string `locationName:"ruleName" min:"1" type:"string"`
  5856. // The SQL statement used to query the topic. When using a SQL query with multiple
  5857. // lines, be sure to escape the newline characters.
  5858. Sql *string `locationName:"sql" type:"string"`
  5859. }
  5860. // String returns the string representation
  5861. func (s TopicRule) String() string {
  5862. return awsutil.Prettify(s)
  5863. }
  5864. // GoString returns the string representation
  5865. func (s TopicRule) GoString() string {
  5866. return s.String()
  5867. }
  5868. // Describes a rule.
  5869. type TopicRuleListItem struct {
  5870. _ struct{} `type:"structure"`
  5871. // The date and time the rule was created.
  5872. CreatedAt *time.Time `locationName:"createdAt" type:"timestamp" timestampFormat:"unix"`
  5873. // The rule ARN.
  5874. RuleArn *string `locationName:"ruleArn" type:"string"`
  5875. // Specifies whether the rule is disabled.
  5876. RuleDisabled *bool `locationName:"ruleDisabled" type:"boolean"`
  5877. // The name of the rule.
  5878. RuleName *string `locationName:"ruleName" min:"1" type:"string"`
  5879. // The pattern for the topic names that apply.
  5880. TopicPattern *string `locationName:"topicPattern" type:"string"`
  5881. }
  5882. // String returns the string representation
  5883. func (s TopicRuleListItem) String() string {
  5884. return awsutil.Prettify(s)
  5885. }
  5886. // GoString returns the string representation
  5887. func (s TopicRuleListItem) GoString() string {
  5888. return s.String()
  5889. }
  5890. // Describes a rule.
  5891. type TopicRulePayload struct {
  5892. _ struct{} `type:"structure"`
  5893. // The actions associated with the rule.
  5894. Actions []*Action `locationName:"actions" type:"list" required:"true"`
  5895. // The version of the SQL rules engine to use when evaluating the rule.
  5896. AwsIotSqlVersion *string `locationName:"awsIotSqlVersion" type:"string"`
  5897. // The description of the rule.
  5898. Description *string `locationName:"description" type:"string"`
  5899. // Specifies whether the rule is disabled.
  5900. RuleDisabled *bool `locationName:"ruleDisabled" type:"boolean"`
  5901. // The SQL statement used to query the topic. For more information, see AWS
  5902. // IoT SQL Reference (http://docs.aws.amazon.com/iot/latest/developerguide/iot-rules.html#aws-iot-sql-reference)
  5903. // in the AWS IoT Developer Guide.
  5904. Sql *string `locationName:"sql" type:"string" required:"true"`
  5905. }
  5906. // String returns the string representation
  5907. func (s TopicRulePayload) String() string {
  5908. return awsutil.Prettify(s)
  5909. }
  5910. // GoString returns the string representation
  5911. func (s TopicRulePayload) GoString() string {
  5912. return s.String()
  5913. }
  5914. // Validate inspects the fields of the type to determine if they are valid.
  5915. func (s *TopicRulePayload) Validate() error {
  5916. invalidParams := request.ErrInvalidParams{Context: "TopicRulePayload"}
  5917. if s.Actions == nil {
  5918. invalidParams.Add(request.NewErrParamRequired("Actions"))
  5919. }
  5920. if s.Sql == nil {
  5921. invalidParams.Add(request.NewErrParamRequired("Sql"))
  5922. }
  5923. if s.Actions != nil {
  5924. for i, v := range s.Actions {
  5925. if v == nil {
  5926. continue
  5927. }
  5928. if err := v.Validate(); err != nil {
  5929. invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Actions", i), err.(request.ErrInvalidParams))
  5930. }
  5931. }
  5932. }
  5933. if invalidParams.Len() > 0 {
  5934. return invalidParams
  5935. }
  5936. return nil
  5937. }
  5938. // The input for the TransferCertificate operation.
  5939. type TransferCertificateInput struct {
  5940. _ struct{} `type:"structure"`
  5941. // The ID of the certificate.
  5942. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  5943. // The AWS account.
  5944. TargetAwsAccount *string `location:"querystring" locationName:"targetAwsAccount" type:"string" required:"true"`
  5945. // The transfer message.
  5946. TransferMessage *string `locationName:"transferMessage" type:"string"`
  5947. }
  5948. // String returns the string representation
  5949. func (s TransferCertificateInput) String() string {
  5950. return awsutil.Prettify(s)
  5951. }
  5952. // GoString returns the string representation
  5953. func (s TransferCertificateInput) GoString() string {
  5954. return s.String()
  5955. }
  5956. // Validate inspects the fields of the type to determine if they are valid.
  5957. func (s *TransferCertificateInput) Validate() error {
  5958. invalidParams := request.ErrInvalidParams{Context: "TransferCertificateInput"}
  5959. if s.CertificateId == nil {
  5960. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  5961. }
  5962. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  5963. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  5964. }
  5965. if s.TargetAwsAccount == nil {
  5966. invalidParams.Add(request.NewErrParamRequired("TargetAwsAccount"))
  5967. }
  5968. if invalidParams.Len() > 0 {
  5969. return invalidParams
  5970. }
  5971. return nil
  5972. }
  5973. // The output from the TransferCertificate operation.
  5974. type TransferCertificateOutput struct {
  5975. _ struct{} `type:"structure"`
  5976. // The ARN of the certificate.
  5977. TransferredCertificateArn *string `locationName:"transferredCertificateArn" type:"string"`
  5978. }
  5979. // String returns the string representation
  5980. func (s TransferCertificateOutput) String() string {
  5981. return awsutil.Prettify(s)
  5982. }
  5983. // GoString returns the string representation
  5984. func (s TransferCertificateOutput) GoString() string {
  5985. return s.String()
  5986. }
  5987. // Data used to transfer a certificate to an AWS account.
  5988. type TransferData struct {
  5989. _ struct{} `type:"structure"`
  5990. // The date the transfer was accepted.
  5991. AcceptDate *time.Time `locationName:"acceptDate" type:"timestamp" timestampFormat:"unix"`
  5992. // The date the transfer was rejected.
  5993. RejectDate *time.Time `locationName:"rejectDate" type:"timestamp" timestampFormat:"unix"`
  5994. // The reason why the transfer was rejected.
  5995. RejectReason *string `locationName:"rejectReason" type:"string"`
  5996. // The date the transfer took place.
  5997. TransferDate *time.Time `locationName:"transferDate" type:"timestamp" timestampFormat:"unix"`
  5998. // The transfer message.
  5999. TransferMessage *string `locationName:"transferMessage" type:"string"`
  6000. }
  6001. // String returns the string representation
  6002. func (s TransferData) String() string {
  6003. return awsutil.Prettify(s)
  6004. }
  6005. // GoString returns the string representation
  6006. func (s TransferData) GoString() string {
  6007. return s.String()
  6008. }
  6009. // The input to the UpdateCACertificate operation.
  6010. type UpdateCACertificateInput struct {
  6011. _ struct{} `type:"structure"`
  6012. // The CA certificate identifier.
  6013. CertificateId *string `location:"uri" locationName:"caCertificateId" min:"64" type:"string" required:"true"`
  6014. // The new value for the auto registration status. Valid values are: "ENABLE"
  6015. // or "DISABLE".
  6016. NewAutoRegistrationStatus *string `location:"querystring" locationName:"newAutoRegistrationStatus" type:"string" enum:"AutoRegistrationStatus"`
  6017. // The updated status of the CA certificate.
  6018. //
  6019. // Note: The status value REGISTER_INACTIVE is deprecated and should not be
  6020. // used.
  6021. NewStatus *string `location:"querystring" locationName:"newStatus" type:"string" enum:"CACertificateStatus"`
  6022. }
  6023. // String returns the string representation
  6024. func (s UpdateCACertificateInput) String() string {
  6025. return awsutil.Prettify(s)
  6026. }
  6027. // GoString returns the string representation
  6028. func (s UpdateCACertificateInput) GoString() string {
  6029. return s.String()
  6030. }
  6031. // Validate inspects the fields of the type to determine if they are valid.
  6032. func (s *UpdateCACertificateInput) Validate() error {
  6033. invalidParams := request.ErrInvalidParams{Context: "UpdateCACertificateInput"}
  6034. if s.CertificateId == nil {
  6035. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  6036. }
  6037. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  6038. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  6039. }
  6040. if invalidParams.Len() > 0 {
  6041. return invalidParams
  6042. }
  6043. return nil
  6044. }
  6045. type UpdateCACertificateOutput struct {
  6046. _ struct{} `type:"structure"`
  6047. }
  6048. // String returns the string representation
  6049. func (s UpdateCACertificateOutput) String() string {
  6050. return awsutil.Prettify(s)
  6051. }
  6052. // GoString returns the string representation
  6053. func (s UpdateCACertificateOutput) GoString() string {
  6054. return s.String()
  6055. }
  6056. // The input for the UpdateCertificate operation.
  6057. type UpdateCertificateInput struct {
  6058. _ struct{} `type:"structure"`
  6059. // The ID of the certificate.
  6060. CertificateId *string `location:"uri" locationName:"certificateId" min:"64" type:"string" required:"true"`
  6061. // The new status.
  6062. //
  6063. // Note: Setting the status to PENDING_TRANSFER will result in an exception
  6064. // being thrown. PENDING_TRANSFER is a status used internally by AWS IoT. It
  6065. // is not intended for developer use.
  6066. //
  6067. // Note: The status value REGISTER_INACTIVE is deprecated and should not be
  6068. // used.
  6069. NewStatus *string `location:"querystring" locationName:"newStatus" type:"string" required:"true" enum:"CertificateStatus"`
  6070. }
  6071. // String returns the string representation
  6072. func (s UpdateCertificateInput) String() string {
  6073. return awsutil.Prettify(s)
  6074. }
  6075. // GoString returns the string representation
  6076. func (s UpdateCertificateInput) GoString() string {
  6077. return s.String()
  6078. }
  6079. // Validate inspects the fields of the type to determine if they are valid.
  6080. func (s *UpdateCertificateInput) Validate() error {
  6081. invalidParams := request.ErrInvalidParams{Context: "UpdateCertificateInput"}
  6082. if s.CertificateId == nil {
  6083. invalidParams.Add(request.NewErrParamRequired("CertificateId"))
  6084. }
  6085. if s.CertificateId != nil && len(*s.CertificateId) < 64 {
  6086. invalidParams.Add(request.NewErrParamMinLen("CertificateId", 64))
  6087. }
  6088. if s.NewStatus == nil {
  6089. invalidParams.Add(request.NewErrParamRequired("NewStatus"))
  6090. }
  6091. if invalidParams.Len() > 0 {
  6092. return invalidParams
  6093. }
  6094. return nil
  6095. }
  6096. type UpdateCertificateOutput struct {
  6097. _ struct{} `type:"structure"`
  6098. }
  6099. // String returns the string representation
  6100. func (s UpdateCertificateOutput) String() string {
  6101. return awsutil.Prettify(s)
  6102. }
  6103. // GoString returns the string representation
  6104. func (s UpdateCertificateOutput) GoString() string {
  6105. return s.String()
  6106. }
  6107. // The input for the UpdateThing operation.
  6108. type UpdateThingInput struct {
  6109. _ struct{} `type:"structure"`
  6110. // A list of thing attributes, a JSON string containing name-value pairs. For
  6111. // example:
  6112. //
  6113. // {\"attributes\":{\"name1\":\"value2\"}})
  6114. //
  6115. // This data is used to add new attributes or update existing attributes.
  6116. AttributePayload *AttributePayload `locationName:"attributePayload" type:"structure"`
  6117. // The expected version of the thing record in the registry. If the version
  6118. // of the record in the registry does not match the expected version specified
  6119. // in the request, the UpdateThing request is rejected with a VersionConflictException.
  6120. ExpectedVersion *int64 `locationName:"expectedVersion" type:"long"`
  6121. // Remove a thing type association. If true, the assocation is removed.
  6122. RemoveThingType *bool `locationName:"removeThingType" type:"boolean"`
  6123. // The name of the thing to update.
  6124. ThingName *string `location:"uri" locationName:"thingName" min:"1" type:"string" required:"true"`
  6125. // The name of the thing type.
  6126. ThingTypeName *string `locationName:"thingTypeName" min:"1" type:"string"`
  6127. }
  6128. // String returns the string representation
  6129. func (s UpdateThingInput) String() string {
  6130. return awsutil.Prettify(s)
  6131. }
  6132. // GoString returns the string representation
  6133. func (s UpdateThingInput) GoString() string {
  6134. return s.String()
  6135. }
  6136. // Validate inspects the fields of the type to determine if they are valid.
  6137. func (s *UpdateThingInput) Validate() error {
  6138. invalidParams := request.ErrInvalidParams{Context: "UpdateThingInput"}
  6139. if s.ThingName == nil {
  6140. invalidParams.Add(request.NewErrParamRequired("ThingName"))
  6141. }
  6142. if s.ThingName != nil && len(*s.ThingName) < 1 {
  6143. invalidParams.Add(request.NewErrParamMinLen("ThingName", 1))
  6144. }
  6145. if s.ThingTypeName != nil && len(*s.ThingTypeName) < 1 {
  6146. invalidParams.Add(request.NewErrParamMinLen("ThingTypeName", 1))
  6147. }
  6148. if invalidParams.Len() > 0 {
  6149. return invalidParams
  6150. }
  6151. return nil
  6152. }
  6153. // The output from the UpdateThing operation.
  6154. type UpdateThingOutput struct {
  6155. _ struct{} `type:"structure"`
  6156. }
  6157. // String returns the string representation
  6158. func (s UpdateThingOutput) String() string {
  6159. return awsutil.Prettify(s)
  6160. }
  6161. // GoString returns the string representation
  6162. func (s UpdateThingOutput) GoString() string {
  6163. return s.String()
  6164. }
  6165. const (
  6166. // @enum AutoRegistrationStatus
  6167. AutoRegistrationStatusEnable = "ENABLE"
  6168. // @enum AutoRegistrationStatus
  6169. AutoRegistrationStatusDisable = "DISABLE"
  6170. )
  6171. const (
  6172. // @enum CACertificateStatus
  6173. CACertificateStatusActive = "ACTIVE"
  6174. // @enum CACertificateStatus
  6175. CACertificateStatusInactive = "INACTIVE"
  6176. )
  6177. const (
  6178. // @enum CertificateStatus
  6179. CertificateStatusActive = "ACTIVE"
  6180. // @enum CertificateStatus
  6181. CertificateStatusInactive = "INACTIVE"
  6182. // @enum CertificateStatus
  6183. CertificateStatusRevoked = "REVOKED"
  6184. // @enum CertificateStatus
  6185. CertificateStatusPendingTransfer = "PENDING_TRANSFER"
  6186. // @enum CertificateStatus
  6187. CertificateStatusRegisterInactive = "REGISTER_INACTIVE"
  6188. // @enum CertificateStatus
  6189. CertificateStatusPendingActivation = "PENDING_ACTIVATION"
  6190. )
  6191. const (
  6192. // @enum DynamoKeyType
  6193. DynamoKeyTypeString = "STRING"
  6194. // @enum DynamoKeyType
  6195. DynamoKeyTypeNumber = "NUMBER"
  6196. )
  6197. const (
  6198. // @enum LogLevel
  6199. LogLevelDebug = "DEBUG"
  6200. // @enum LogLevel
  6201. LogLevelInfo = "INFO"
  6202. // @enum LogLevel
  6203. LogLevelError = "ERROR"
  6204. // @enum LogLevel
  6205. LogLevelWarn = "WARN"
  6206. // @enum LogLevel
  6207. LogLevelDisabled = "DISABLED"
  6208. )
  6209. const (
  6210. // @enum MessageFormat
  6211. MessageFormatRaw = "RAW"
  6212. // @enum MessageFormat
  6213. MessageFormatJson = "JSON"
  6214. )