rest-xml.json 45 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924
  1. [
  2. {
  3. "description": "Basic XML serialization",
  4. "metadata": {
  5. "protocol": "rest-xml",
  6. "apiVersion": "2014-01-01"
  7. },
  8. "shapes": {
  9. "InputShape": {
  10. "type": "structure",
  11. "members": {
  12. "Name": {
  13. "shape": "StringType"
  14. },
  15. "Description": {
  16. "shape": "StringType"
  17. }
  18. }
  19. },
  20. "StringType": {
  21. "type": "string"
  22. }
  23. },
  24. "cases": [
  25. {
  26. "given": {
  27. "http": {
  28. "method": "POST",
  29. "requestUri": "/2014-01-01/hostedzone"
  30. },
  31. "input": {
  32. "shape": "InputShape",
  33. "locationName": "OperationRequest",
  34. "xmlNamespace": {"uri": "https://foo/"}
  35. },
  36. "name": "OperationName"
  37. },
  38. "params": {
  39. "Name": "foo",
  40. "Description": "bar"
  41. },
  42. "serialized": {
  43. "method": "POST",
  44. "body": "<OperationRequest xmlns=\"https://foo/\"><Name>foo</Name><Description>bar</Description></OperationRequest>",
  45. "uri": "/2014-01-01/hostedzone",
  46. "headers": {}
  47. }
  48. },
  49. {
  50. "given": {
  51. "http": {
  52. "method": "PUT",
  53. "requestUri": "/2014-01-01/hostedzone"
  54. },
  55. "input": {
  56. "shape": "InputShape",
  57. "locationName": "OperationRequest",
  58. "xmlNamespace": {"uri": "https://foo/"}
  59. },
  60. "name": "OperationName"
  61. },
  62. "params": {
  63. "Name": "foo",
  64. "Description": "bar"
  65. },
  66. "serialized": {
  67. "method": "PUT",
  68. "body": "<OperationRequest xmlns=\"https://foo/\"><Name>foo</Name><Description>bar</Description></OperationRequest>",
  69. "uri": "/2014-01-01/hostedzone",
  70. "headers": {}
  71. }
  72. },
  73. {
  74. "given": {
  75. "http": {
  76. "method": "GET",
  77. "requestUri": "/2014-01-01/hostedzone"
  78. },
  79. "name": "OperationName"
  80. },
  81. "params": {},
  82. "serialized": {
  83. "method": "GET",
  84. "body": "",
  85. "uri": "/2014-01-01/hostedzone",
  86. "headers": {}
  87. }
  88. }
  89. ]
  90. },
  91. {
  92. "description": "Serialize other scalar types",
  93. "metadata": {
  94. "protocol": "rest-xml",
  95. "apiVersion": "2014-01-01"
  96. },
  97. "shapes": {
  98. "InputShape": {
  99. "type": "structure",
  100. "members": {
  101. "First": {
  102. "shape": "BoolType"
  103. },
  104. "Second": {
  105. "shape": "BoolType"
  106. },
  107. "Third": {
  108. "shape": "FloatType"
  109. },
  110. "Fourth": {
  111. "shape": "IntegerType"
  112. }
  113. }
  114. },
  115. "BoolType": {
  116. "type": "boolean"
  117. },
  118. "FloatType": {
  119. "type": "float"
  120. },
  121. "IntegerType": {
  122. "type": "integer"
  123. }
  124. },
  125. "cases": [
  126. {
  127. "given": {
  128. "http": {
  129. "method": "POST",
  130. "requestUri": "/2014-01-01/hostedzone"
  131. },
  132. "input": {
  133. "shape": "InputShape",
  134. "locationName": "OperationRequest",
  135. "xmlNamespace": {"uri": "https://foo/"}
  136. },
  137. "name": "OperationName"
  138. },
  139. "params": {
  140. "First": true,
  141. "Second": false,
  142. "Third": 1.2,
  143. "Fourth": 3
  144. },
  145. "serialized": {
  146. "method": "POST",
  147. "body": "<OperationRequest xmlns=\"https://foo/\"><First>true</First><Second>false</Second><Third>1.2</Third><Fourth>3</Fourth></OperationRequest>",
  148. "uri": "/2014-01-01/hostedzone",
  149. "headers": {}
  150. }
  151. }
  152. ]
  153. },
  154. {
  155. "description": "Nested structures",
  156. "metadata": {
  157. "protocol": "rest-xml",
  158. "apiVersion": "2014-01-01"
  159. },
  160. "shapes": {
  161. "InputShape": {
  162. "type": "structure",
  163. "members": {
  164. "SubStructure": {
  165. "shape": "SubStructure"
  166. },
  167. "Description": {
  168. "shape": "StringType"
  169. }
  170. }
  171. },
  172. "SubStructure": {
  173. "type": "structure",
  174. "members": {
  175. "Foo": {
  176. "shape": "StringType"
  177. },
  178. "Bar": {
  179. "shape": "StringType"
  180. }
  181. }
  182. },
  183. "StringType": {
  184. "type": "string"
  185. }
  186. },
  187. "cases": [
  188. {
  189. "given": {
  190. "http": {
  191. "method": "POST",
  192. "requestUri": "/2014-01-01/hostedzone"
  193. },
  194. "input": {
  195. "shape": "InputShape",
  196. "locationName": "OperationRequest",
  197. "xmlNamespace": {"uri": "https://foo/"}
  198. },
  199. "name": "OperationName"
  200. },
  201. "params": {
  202. "SubStructure": {
  203. "Foo": "a",
  204. "Bar": "b"
  205. },
  206. "Description": "baz"
  207. },
  208. "serialized": {
  209. "method": "POST",
  210. "body": "<OperationRequest xmlns=\"https://foo/\"><SubStructure><Foo>a</Foo><Bar>b</Bar></SubStructure><Description>baz</Description></OperationRequest>",
  211. "uri": "/2014-01-01/hostedzone",
  212. "headers": {}
  213. }
  214. },
  215. {
  216. "given": {
  217. "http": {
  218. "method": "POST",
  219. "requestUri": "/2014-01-01/hostedzone"
  220. },
  221. "input": {
  222. "shape": "InputShape",
  223. "locationName": "OperationRequest",
  224. "xmlNamespace": {"uri": "https://foo/"}
  225. },
  226. "name": "OperationName"
  227. },
  228. "params": {
  229. "SubStructure": {
  230. "Foo": "a",
  231. "Bar": null
  232. },
  233. "Description": "baz"
  234. },
  235. "serialized": {
  236. "method": "POST",
  237. "body": "<OperationRequest xmlns=\"https://foo/\"><SubStructure><Foo>a</Foo></SubStructure><Description>baz</Description></OperationRequest>",
  238. "uri": "/2014-01-01/hostedzone",
  239. "headers": {}
  240. }
  241. }
  242. ]
  243. },
  244. {
  245. "description": "Nested structures",
  246. "metadata": {
  247. "protocol": "rest-xml",
  248. "apiVersion": "2014-01-01"
  249. },
  250. "shapes": {
  251. "InputShape": {
  252. "type": "structure",
  253. "members": {
  254. "SubStructure": {
  255. "shape": "SubStructure"
  256. },
  257. "Description": {
  258. "shape": "StringType"
  259. }
  260. }
  261. },
  262. "SubStructure": {
  263. "type": "structure",
  264. "members": {
  265. "Foo": {
  266. "shape": "StringType"
  267. },
  268. "Bar": {
  269. "shape": "StringType"
  270. }
  271. }
  272. },
  273. "StringType": {
  274. "type": "string"
  275. }
  276. },
  277. "cases": [
  278. {
  279. "given": {
  280. "http": {
  281. "method": "POST",
  282. "requestUri": "/2014-01-01/hostedzone"
  283. },
  284. "input": {
  285. "shape": "InputShape",
  286. "locationName": "OperationRequest",
  287. "xmlNamespace": {"uri": "https://foo/"}
  288. },
  289. "name": "OperationName"
  290. },
  291. "params": {
  292. "SubStructure": {},
  293. "Description": "baz"
  294. },
  295. "serialized": {
  296. "method": "POST",
  297. "body": "<OperationRequest xmlns=\"https://foo/\"><SubStructure /><Description>baz</Description></OperationRequest>",
  298. "uri": "/2014-01-01/hostedzone",
  299. "headers": {}
  300. }
  301. }
  302. ]
  303. },
  304. {
  305. "description": "Non flattened lists",
  306. "metadata": {
  307. "protocol": "rest-xml",
  308. "apiVersion": "2014-01-01"
  309. },
  310. "shapes": {
  311. "InputShape": {
  312. "type": "structure",
  313. "members": {
  314. "ListParam": {
  315. "shape": "ListShape"
  316. }
  317. }
  318. },
  319. "ListShape": {
  320. "type": "list",
  321. "member": {
  322. "shape": "StringType"
  323. }
  324. },
  325. "StringType": {
  326. "type": "string"
  327. }
  328. },
  329. "cases": [
  330. {
  331. "given": {
  332. "http": {
  333. "method": "POST",
  334. "requestUri": "/2014-01-01/hostedzone"
  335. },
  336. "input": {
  337. "shape": "InputShape",
  338. "locationName": "OperationRequest",
  339. "xmlNamespace": {"uri": "https://foo/"}
  340. },
  341. "name": "OperationName"
  342. },
  343. "params": {
  344. "ListParam": [
  345. "one",
  346. "two",
  347. "three"
  348. ]
  349. },
  350. "serialized": {
  351. "method": "POST",
  352. "body": "<OperationRequest xmlns=\"https://foo/\"><ListParam><member>one</member><member>two</member><member>three</member></ListParam></OperationRequest>",
  353. "uri": "/2014-01-01/hostedzone",
  354. "headers": {}
  355. }
  356. }
  357. ]
  358. },
  359. {
  360. "description": "Non flattened lists with locationName",
  361. "metadata": {
  362. "protocol": "rest-xml",
  363. "apiVersion": "2014-01-01"
  364. },
  365. "shapes": {
  366. "InputShape": {
  367. "type": "structure",
  368. "members": {
  369. "ListParam": {
  370. "shape": "ListShape",
  371. "locationName": "AlternateName"
  372. }
  373. }
  374. },
  375. "ListShape": {
  376. "type": "list",
  377. "member": {
  378. "shape": "StringType",
  379. "locationName": "NotMember"
  380. }
  381. },
  382. "StringType": {
  383. "type": "string"
  384. }
  385. },
  386. "cases": [
  387. {
  388. "given": {
  389. "http": {
  390. "method": "POST",
  391. "requestUri": "/2014-01-01/hostedzone"
  392. },
  393. "input": {
  394. "shape": "InputShape",
  395. "locationName": "OperationRequest",
  396. "xmlNamespace": {"uri": "https://foo/"}
  397. },
  398. "name": "OperationName"
  399. },
  400. "params": {
  401. "ListParam": [
  402. "one",
  403. "two",
  404. "three"
  405. ]
  406. },
  407. "serialized": {
  408. "method": "POST",
  409. "body": "<OperationRequest xmlns=\"https://foo/\"><AlternateName><NotMember>one</NotMember><NotMember>two</NotMember><NotMember>three</NotMember></AlternateName></OperationRequest>",
  410. "uri": "/2014-01-01/hostedzone",
  411. "headers": {}
  412. }
  413. }
  414. ]
  415. },
  416. {
  417. "description": "Flattened lists",
  418. "metadata": {
  419. "protocol": "rest-xml",
  420. "apiVersion": "2014-01-01"
  421. },
  422. "shapes": {
  423. "InputShape": {
  424. "type": "structure",
  425. "members": {
  426. "ListParam": {
  427. "shape": "ListShape"
  428. }
  429. }
  430. },
  431. "ListShape": {
  432. "type": "list",
  433. "member": {
  434. "shape": "StringType"
  435. },
  436. "flattened": true
  437. },
  438. "StringType": {
  439. "type": "string"
  440. }
  441. },
  442. "cases": [
  443. {
  444. "given": {
  445. "http": {
  446. "method": "POST",
  447. "requestUri": "/2014-01-01/hostedzone"
  448. },
  449. "input": {
  450. "shape": "InputShape",
  451. "locationName": "OperationRequest",
  452. "xmlNamespace": {"uri": "https://foo/"}
  453. },
  454. "name": "OperationName"
  455. },
  456. "params": {
  457. "ListParam": [
  458. "one",
  459. "two",
  460. "three"
  461. ]
  462. },
  463. "serialized": {
  464. "method": "POST",
  465. "body": "<OperationRequest xmlns=\"https://foo/\"><ListParam>one</ListParam><ListParam>two</ListParam><ListParam>three</ListParam></OperationRequest>",
  466. "uri": "/2014-01-01/hostedzone",
  467. "headers": {}
  468. }
  469. }
  470. ]
  471. },
  472. {
  473. "description": "Flattened lists with locationName",
  474. "metadata": {
  475. "protocol": "rest-xml",
  476. "apiVersion": "2014-01-01"
  477. },
  478. "shapes": {
  479. "InputShape": {
  480. "type": "structure",
  481. "members": {
  482. "ListParam": {
  483. "shape": "ListShape",
  484. "locationName": "item"
  485. }
  486. }
  487. },
  488. "ListShape": {
  489. "type": "list",
  490. "member": {
  491. "shape": "StringType"
  492. },
  493. "flattened": true
  494. },
  495. "StringType": {
  496. "type": "string"
  497. }
  498. },
  499. "cases": [
  500. {
  501. "given": {
  502. "http": {
  503. "method": "POST",
  504. "requestUri": "/2014-01-01/hostedzone"
  505. },
  506. "input": {
  507. "shape": "InputShape",
  508. "locationName": "OperationRequest",
  509. "xmlNamespace": {"uri": "https://foo/"}
  510. },
  511. "name": "OperationName"
  512. },
  513. "params": {
  514. "ListParam": [
  515. "one",
  516. "two",
  517. "three"
  518. ]
  519. },
  520. "serialized": {
  521. "method": "POST",
  522. "body": "<OperationRequest xmlns=\"https://foo/\"><item>one</item><item>two</item><item>three</item></OperationRequest>",
  523. "uri": "/2014-01-01/hostedzone",
  524. "headers": {}
  525. }
  526. }
  527. ]
  528. },
  529. {
  530. "description": "List of structures",
  531. "metadata": {
  532. "protocol": "rest-xml",
  533. "apiVersion": "2014-01-01"
  534. },
  535. "shapes": {
  536. "InputShape": {
  537. "type": "structure",
  538. "members": {
  539. "ListParam": {
  540. "shape": "ListShape",
  541. "locationName": "item"
  542. }
  543. }
  544. },
  545. "ListShape": {
  546. "type": "list",
  547. "member": {
  548. "shape": "SingleFieldStruct"
  549. },
  550. "flattened": true
  551. },
  552. "StringType": {
  553. "type": "string"
  554. },
  555. "SingleFieldStruct": {
  556. "type": "structure",
  557. "members": {
  558. "Element": {
  559. "shape": "StringType",
  560. "locationName": "value"
  561. }
  562. }
  563. }
  564. },
  565. "cases": [
  566. {
  567. "given": {
  568. "http": {
  569. "method": "POST",
  570. "requestUri": "/2014-01-01/hostedzone"
  571. },
  572. "input": {
  573. "shape": "InputShape",
  574. "locationName": "OperationRequest",
  575. "xmlNamespace": {"uri": "https://foo/"}
  576. },
  577. "name": "OperationName"
  578. },
  579. "params": {
  580. "ListParam": [
  581. {
  582. "Element": "one"
  583. },
  584. {
  585. "Element": "two"
  586. },
  587. {
  588. "Element": "three"
  589. }
  590. ]
  591. },
  592. "serialized": {
  593. "method": "POST",
  594. "body": "<OperationRequest xmlns=\"https://foo/\"><item><value>one</value></item><item><value>two</value></item><item><value>three</value></item></OperationRequest>",
  595. "uri": "/2014-01-01/hostedzone",
  596. "headers": {}
  597. }
  598. }
  599. ]
  600. },
  601. {
  602. "description": "Blob shapes",
  603. "metadata": {
  604. "protocol": "rest-xml",
  605. "apiVersion": "2014-01-01"
  606. },
  607. "shapes": {
  608. "InputShape": {
  609. "type": "structure",
  610. "members": {
  611. "StructureParam": {
  612. "shape": "StructureShape"
  613. }
  614. }
  615. },
  616. "StructureShape": {
  617. "type": "structure",
  618. "members": {
  619. "b": {
  620. "shape": "BShape"
  621. }
  622. }
  623. },
  624. "BShape": {
  625. "type": "blob"
  626. }
  627. },
  628. "cases": [
  629. {
  630. "given": {
  631. "http": {
  632. "method": "POST",
  633. "requestUri": "/2014-01-01/hostedzone"
  634. },
  635. "input": {
  636. "shape": "InputShape",
  637. "locationName": "OperationRequest",
  638. "xmlNamespace": {"uri": "https://foo/"}
  639. },
  640. "name": "OperationName"
  641. },
  642. "params": {
  643. "StructureParam": {
  644. "b": "foo"
  645. }
  646. },
  647. "serialized": {
  648. "method": "POST",
  649. "body": "<OperationRequest xmlns=\"https://foo/\"><StructureParam><b>Zm9v</b></StructureParam></OperationRequest>",
  650. "uri": "/2014-01-01/hostedzone",
  651. "headers": {}
  652. }
  653. }
  654. ]
  655. },
  656. {
  657. "description": "Timestamp shapes",
  658. "metadata": {
  659. "protocol": "rest-xml",
  660. "apiVersion": "2014-01-01"
  661. },
  662. "shapes": {
  663. "InputShape": {
  664. "type": "structure",
  665. "members": {
  666. "TimeArg": {
  667. "shape": "TimestampType"
  668. },
  669. "TimeArgInHeader": {
  670. "shape": "TimestampType",
  671. "location": "header",
  672. "locationName": "x-amz-timearg"
  673. },
  674. "TimeArgInQuery": {
  675. "shape": "TimestampType",
  676. "location": "querystring",
  677. "locationName": "TimeQuery"
  678. },
  679. "TimeCustom": {
  680. "timestampFormat": "rfc822",
  681. "shape": "TimestampType"
  682. },
  683. "TimeCustomInHeader": {
  684. "timestampFormat": "unixTimestamp",
  685. "shape": "TimestampType",
  686. "location": "header",
  687. "locationName": "x-amz-timecustom-header"
  688. },
  689. "TimeCustomInQuery": {
  690. "timestampFormat": "unixTimestamp",
  691. "shape": "TimestampType",
  692. "location": "querystring",
  693. "locationName": "TimeCustomQuery"
  694. },
  695. "TimeFormat": {
  696. "shape": "TimestampFormatRfcType"
  697. },
  698. "TimeFormatInHeader": {
  699. "shape": "TimestampFormatUnixType",
  700. "location": "header",
  701. "locationName": "x-amz-timeformat-header"
  702. },
  703. "TimeFormatInQuery": {
  704. "shape": "TimestampFormatUnixType",
  705. "location": "querystring",
  706. "locationName": "TimeFormatQuery"
  707. }
  708. }
  709. },
  710. "TimestampFormatRfcType": {
  711. "timestampFormat": "rfc822",
  712. "type": "timestamp"
  713. },
  714. "TimestampFormatUnixType": {
  715. "timestampFormat": "unixTimestamp",
  716. "type": "timestamp"
  717. },
  718. "TimestampType": {
  719. "type": "timestamp"
  720. }
  721. },
  722. "cases": [
  723. {
  724. "given": {
  725. "http": {
  726. "method": "POST",
  727. "requestUri": "/2014-01-01/hostedzone"
  728. },
  729. "input": {
  730. "shape": "InputShape",
  731. "locationName": "TimestampStructure",
  732. "xmlNamespace": {"uri": "https://foo/"}
  733. },
  734. "name": "OperationName"
  735. },
  736. "params": {
  737. "TimeArg": 1422172800,
  738. "TimeArgInQuery": 1422172800,
  739. "TimeArgInHeader": 1422172800,
  740. "TimeCustom": 1422172800,
  741. "TimeCustomInQuery": 1422172800,
  742. "TimeCustomInHeader": 1422172800,
  743. "TimeFormat": 1422172800,
  744. "TimeFormatInQuery": 1422172800,
  745. "TimeFormatInHeader": 1422172800
  746. },
  747. "serialized": {
  748. "method": "POST",
  749. "body": "<TimestampStructure xmlns=\"https://foo/\"><TimeArg>2015-01-25T08:00:00Z</TimeArg><TimeCustom>Sun, 25 Jan 2015 08:00:00 GMT</TimeCustom><TimeFormat>Sun, 25 Jan 2015 08:00:00 GMT</TimeFormat></TimestampStructure>",
  750. "uri": "/2014-01-01/hostedzone?TimeQuery=2015-01-25T08%3A00%3A00Z&TimeCustomQuery=1422172800&TimeFormatQuery=1422172800",
  751. "headers": {
  752. "x-amz-timearg": "Sun, 25 Jan 2015 08:00:00 GMT",
  753. "x-amz-timecustom-header": "1422172800",
  754. "x-amz-timeformat-header": "1422172800"
  755. }
  756. }
  757. }
  758. ]
  759. },
  760. {
  761. "description": "Header maps",
  762. "metadata": {
  763. "protocol": "rest-xml",
  764. "apiVersion": "2014-01-01"
  765. },
  766. "shapes": {
  767. "InputShape": {
  768. "type": "structure",
  769. "members": {
  770. "foo": {
  771. "shape": "FooShape"
  772. }
  773. }
  774. },
  775. "FooShape": {
  776. "type": "map",
  777. "location": "headers",
  778. "locationName": "x-foo-",
  779. "key": {
  780. "shape": "FooKeyValue"
  781. },
  782. "value": {
  783. "shape": "FooKeyValue"
  784. }
  785. },
  786. "FooKeyValue": {
  787. "type": "string"
  788. }
  789. },
  790. "cases": [
  791. {
  792. "given": {
  793. "http": {
  794. "method": "POST",
  795. "requestUri": "/"
  796. },
  797. "input": {
  798. "shape": "InputShape",
  799. "locationName": "OperationRequest",
  800. "xmlNamespace": {"uri": "https://foo/"}
  801. },
  802. "name": "OperationName"
  803. },
  804. "params": {
  805. "foo": {
  806. "a": "b",
  807. "c": "d"
  808. }
  809. },
  810. "serialized": {
  811. "method": "POST",
  812. "body": "",
  813. "uri": "/",
  814. "headers": {
  815. "x-foo-a": "b",
  816. "x-foo-c": "d"
  817. }
  818. }
  819. }
  820. ]
  821. },
  822. {
  823. "description": "Querystring list of strings",
  824. "metadata": {
  825. "protocol": "rest-xml",
  826. "apiVersion": "2014-01-01"
  827. },
  828. "shapes": {
  829. "InputShape": {
  830. "type": "structure",
  831. "members": {
  832. "Items": {
  833. "shape": "StringList",
  834. "location": "querystring",
  835. "locationName": "item"
  836. }
  837. }
  838. },
  839. "StringList": {
  840. "type": "list",
  841. "member": {
  842. "shape": "String"
  843. }
  844. },
  845. "String": {
  846. "type": "string"
  847. }
  848. },
  849. "cases": [
  850. {
  851. "given": {
  852. "http": {
  853. "method": "GET",
  854. "requestUri": "/path"
  855. },
  856. "input": {
  857. "shape": "InputShape"
  858. },
  859. "name": "OperationName"
  860. },
  861. "params": {
  862. "Items": ["value1", "value2"]
  863. },
  864. "serialized": {
  865. "body": "",
  866. "uri": "/path?item=value1&item=value2",
  867. "headers": {}
  868. }
  869. }
  870. ]
  871. },
  872. {
  873. "description": "String to string maps in querystring",
  874. "metadata": {
  875. "protocol": "rest-xml",
  876. "apiVersion": "2014-01-01"
  877. },
  878. "shapes": {
  879. "InputShape": {
  880. "type": "structure",
  881. "members": {
  882. "PipelineId": {
  883. "shape": "StringType",
  884. "location": "uri"
  885. },
  886. "QueryDoc": {
  887. "shape": "MapStringStringType",
  888. "location": "querystring"
  889. }
  890. }
  891. },
  892. "MapStringStringType": {
  893. "type": "map",
  894. "key": {
  895. "shape": "StringType"
  896. },
  897. "value": {
  898. "shape": "StringType"
  899. }
  900. },
  901. "StringType": {
  902. "type": "string"
  903. }
  904. },
  905. "cases": [
  906. {
  907. "given": {
  908. "http": {
  909. "method": "GET",
  910. "requestUri": "/2014-01-01/jobsByPipeline/{PipelineId}"
  911. },
  912. "input": {
  913. "shape": "InputShape"
  914. },
  915. "name": "OperationName"
  916. },
  917. "params": {
  918. "PipelineId": "foo",
  919. "QueryDoc": {
  920. "bar": "baz",
  921. "fizz": "buzz"
  922. }
  923. },
  924. "serialized": {
  925. "body": "",
  926. "uri": "/2014-01-01/jobsByPipeline/foo?bar=baz&fizz=buzz",
  927. "headers": {}
  928. }
  929. }
  930. ]
  931. },
  932. {
  933. "description": "String to string list maps in querystring",
  934. "metadata": {
  935. "protocol": "rest-xml",
  936. "apiVersion": "2014-01-01"
  937. },
  938. "shapes": {
  939. "InputShape": {
  940. "type": "structure",
  941. "members": {
  942. "PipelineId": {
  943. "shape": "StringType",
  944. "location": "uri"
  945. },
  946. "QueryDoc": {
  947. "shape": "MapStringStringListType",
  948. "location": "querystring"
  949. }
  950. }
  951. },
  952. "MapStringStringListType": {
  953. "type": "map",
  954. "key": {
  955. "shape": "StringType"
  956. },
  957. "value": {
  958. "shape": "StringListType"
  959. }
  960. },
  961. "StringListType": {
  962. "type": "list",
  963. "member": {
  964. "shape": "StringType"
  965. }
  966. },
  967. "StringType": {
  968. "type": "string"
  969. }
  970. },
  971. "cases": [
  972. {
  973. "given": {
  974. "http": {
  975. "method": "GET",
  976. "requestUri": "/2014-01-01/jobsByPipeline/{PipelineId}"
  977. },
  978. "input": {
  979. "shape": "InputShape"
  980. },
  981. "name": "OperationName"
  982. },
  983. "params": {
  984. "PipelineId": "id",
  985. "QueryDoc": {
  986. "foo": ["bar", "baz"],
  987. "fizz": ["buzz", "pop"]
  988. }
  989. },
  990. "serialized": {
  991. "body": "",
  992. "uri": "/2014-01-01/jobsByPipeline/id?foo=bar&foo=baz&fizz=buzz&fizz=pop",
  993. "headers": {}
  994. }
  995. }
  996. ]
  997. },
  998. {
  999. "description": "Boolean in querystring",
  1000. "metadata": {
  1001. "protocol": "rest-xml",
  1002. "apiVersion": "2014-01-01"
  1003. },
  1004. "shapes": {
  1005. "InputShape": {
  1006. "type": "structure",
  1007. "members": {
  1008. "BoolQuery": {
  1009. "shape": "BoolType",
  1010. "location": "querystring",
  1011. "locationName": "bool-query"
  1012. }
  1013. }
  1014. },
  1015. "BoolType": {
  1016. "type": "boolean"
  1017. }
  1018. },
  1019. "cases": [
  1020. {
  1021. "given": {
  1022. "http": {
  1023. "method": "GET",
  1024. "requestUri": "/path"
  1025. },
  1026. "input": {
  1027. "shape": "InputShape"
  1028. },
  1029. "name": "OperationName"
  1030. },
  1031. "params": {
  1032. "BoolQuery": true
  1033. },
  1034. "serialized": {
  1035. "body": "",
  1036. "uri": "/path?bool-query=true",
  1037. "headers": {}
  1038. }
  1039. },
  1040. {
  1041. "given": {
  1042. "http": {
  1043. "method": "GET",
  1044. "requestUri": "/path"
  1045. },
  1046. "input": {
  1047. "shape": "InputShape"
  1048. },
  1049. "name": "OperationName"
  1050. },
  1051. "params": {
  1052. "BoolQuery": false
  1053. },
  1054. "serialized": {
  1055. "body": "",
  1056. "uri": "/path?bool-query=false",
  1057. "headers": {}
  1058. }
  1059. }
  1060. ]
  1061. },
  1062. {
  1063. "description": "String payload",
  1064. "metadata": {
  1065. "protocol": "rest-xml",
  1066. "apiVersion": "2014-01-01"
  1067. },
  1068. "shapes": {
  1069. "InputShape": {
  1070. "type": "structure",
  1071. "members": {
  1072. "foo": {
  1073. "shape": "FooShape"
  1074. }
  1075. },
  1076. "payload": "foo"
  1077. },
  1078. "FooShape": {
  1079. "type": "string"
  1080. }
  1081. },
  1082. "cases": [
  1083. {
  1084. "given": {
  1085. "http": {
  1086. "method": "POST",
  1087. "requestUri": "/"
  1088. },
  1089. "input": {
  1090. "shape": "InputShape"
  1091. },
  1092. "name": "OperationName"
  1093. },
  1094. "params": {
  1095. "foo": "bar"
  1096. },
  1097. "serialized": {
  1098. "method": "POST",
  1099. "body": "bar",
  1100. "uri": "/"
  1101. }
  1102. }
  1103. ]
  1104. },
  1105. {
  1106. "description": "Blob payload",
  1107. "metadata": {
  1108. "protocol": "rest-xml",
  1109. "apiVersion": "2014-01-01"
  1110. },
  1111. "shapes": {
  1112. "InputShape": {
  1113. "type": "structure",
  1114. "members": {
  1115. "foo": {
  1116. "shape": "FooShape"
  1117. }
  1118. },
  1119. "payload": "foo"
  1120. },
  1121. "FooShape": {
  1122. "type": "blob"
  1123. }
  1124. },
  1125. "cases": [
  1126. {
  1127. "given": {
  1128. "http": {
  1129. "method": "POST",
  1130. "requestUri": "/"
  1131. },
  1132. "input": {
  1133. "shape": "InputShape"
  1134. },
  1135. "name": "OperationName"
  1136. },
  1137. "params": {
  1138. "foo": "bar"
  1139. },
  1140. "serialized": {
  1141. "method": "POST",
  1142. "body": "bar",
  1143. "uri": "/"
  1144. }
  1145. },
  1146. {
  1147. "given": {
  1148. "http": {
  1149. "method": "POST",
  1150. "requestUri": "/"
  1151. },
  1152. "input": {
  1153. "shape": "InputShape"
  1154. },
  1155. "name": "OperationName"
  1156. },
  1157. "params": {
  1158. },
  1159. "serialized": {
  1160. "method": "POST",
  1161. "body": "",
  1162. "uri": "/"
  1163. }
  1164. }
  1165. ]
  1166. },
  1167. {
  1168. "description": "Structure payload",
  1169. "metadata": {
  1170. "protocol": "rest-xml",
  1171. "apiVersion": "2014-01-01"
  1172. },
  1173. "shapes": {
  1174. "InputShape": {
  1175. "type": "structure",
  1176. "members": {
  1177. "foo": {
  1178. "shape": "FooShape"
  1179. }
  1180. },
  1181. "payload": "foo"
  1182. },
  1183. "FooShape": {
  1184. "locationName": "foo",
  1185. "type": "structure",
  1186. "members": {
  1187. "baz": {
  1188. "shape": "BazShape"
  1189. }
  1190. }
  1191. },
  1192. "BazShape": {
  1193. "type": "string"
  1194. }
  1195. },
  1196. "cases": [
  1197. {
  1198. "given": {
  1199. "http": {
  1200. "method": "POST",
  1201. "requestUri": "/"
  1202. },
  1203. "input": {
  1204. "shape": "InputShape"
  1205. },
  1206. "name": "OperationName"
  1207. },
  1208. "params": {
  1209. "foo": {
  1210. "baz": "bar"
  1211. }
  1212. },
  1213. "serialized": {
  1214. "method": "POST",
  1215. "body": "<foo><baz>bar</baz></foo>",
  1216. "uri": "/"
  1217. }
  1218. },
  1219. {
  1220. "given": {
  1221. "http": {
  1222. "method": "POST",
  1223. "requestUri": "/"
  1224. },
  1225. "input": {
  1226. "shape": "InputShape"
  1227. },
  1228. "name": "OperationName"
  1229. },
  1230. "params": {},
  1231. "serialized": {
  1232. "method": "POST",
  1233. "body": "",
  1234. "uri": "/"
  1235. }
  1236. },
  1237. {
  1238. "given": {
  1239. "http": {
  1240. "method": "POST",
  1241. "requestUri": "/"
  1242. },
  1243. "input": {
  1244. "shape": "InputShape"
  1245. },
  1246. "name": "OperationName"
  1247. },
  1248. "params": {
  1249. "foo": {}
  1250. },
  1251. "serialized": {
  1252. "method": "POST",
  1253. "body": "<foo />",
  1254. "uri": "/"
  1255. }
  1256. },
  1257. {
  1258. "given": {
  1259. "http": {
  1260. "method": "POST",
  1261. "requestUri": "/"
  1262. },
  1263. "input": {
  1264. "shape": "InputShape"
  1265. },
  1266. "name": "OperationName"
  1267. },
  1268. "params": {
  1269. "foo": null
  1270. },
  1271. "serialized": {
  1272. "method": "POST",
  1273. "body": "",
  1274. "uri": "/"
  1275. }
  1276. }
  1277. ]
  1278. },
  1279. {
  1280. "description": "XML Attribute",
  1281. "metadata": {
  1282. "protocol": "rest-xml",
  1283. "apiVersion": "2014-01-01"
  1284. },
  1285. "shapes": {
  1286. "InputShape": {
  1287. "type": "structure",
  1288. "members": {
  1289. "Grant": {
  1290. "shape": "Grant"
  1291. }
  1292. },
  1293. "payload": "Grant"
  1294. },
  1295. "Grant": {
  1296. "type": "structure",
  1297. "locationName": "Grant",
  1298. "members": {
  1299. "Grantee": {
  1300. "shape": "Grantee"
  1301. }
  1302. }
  1303. },
  1304. "Grantee": {
  1305. "type": "structure",
  1306. "members": {
  1307. "Type": {
  1308. "shape": "Type",
  1309. "locationName": "xsi:type",
  1310. "xmlAttribute": true
  1311. },
  1312. "EmailAddress": {
  1313. "shape": "StringType"
  1314. }
  1315. },
  1316. "xmlNamespace": {
  1317. "prefix": "xsi",
  1318. "uri":"http://www.w3.org/2001/XMLSchema-instance"
  1319. }
  1320. },
  1321. "Type": {
  1322. "type": "string"
  1323. },
  1324. "StringType": {
  1325. "type": "string"
  1326. }
  1327. },
  1328. "cases": [
  1329. {
  1330. "given": {
  1331. "http": {
  1332. "method": "POST",
  1333. "requestUri": "/"
  1334. },
  1335. "input": {
  1336. "shape": "InputShape"
  1337. },
  1338. "name": "OperationName"
  1339. },
  1340. "params": {
  1341. "Grant": {
  1342. "Grantee": {
  1343. "EmailAddress": "foo@example.com",
  1344. "Type": "CanonicalUser"
  1345. }
  1346. }
  1347. },
  1348. "serialized": {
  1349. "method": "POST",
  1350. "body": "<Grant><Grantee xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:type=\"CanonicalUser\"><EmailAddress>foo@example.com</EmailAddress></Grantee></Grant>",
  1351. "uri": "/"
  1352. }
  1353. }
  1354. ]
  1355. },
  1356. {
  1357. "description": "Greedy keys",
  1358. "metadata": {
  1359. "protocol": "rest-xml",
  1360. "apiVersion": "2014-01-01"
  1361. },
  1362. "shapes": {
  1363. "InputShape": {
  1364. "type": "structure",
  1365. "members": {
  1366. "Bucket": {
  1367. "shape": "BucketShape",
  1368. "location": "uri"
  1369. },
  1370. "Key": {
  1371. "shape": "KeyShape",
  1372. "location": "uri"
  1373. }
  1374. }
  1375. },
  1376. "BucketShape": {
  1377. "type": "string"
  1378. },
  1379. "KeyShape": {
  1380. "type": "string"
  1381. }
  1382. },
  1383. "cases": [
  1384. {
  1385. "given": {
  1386. "http": {
  1387. "method": "GET",
  1388. "requestUri": "/{Bucket}/{Key+}"
  1389. },
  1390. "input": {
  1391. "shape": "InputShape"
  1392. },
  1393. "name": "OperationName"
  1394. },
  1395. "params": {
  1396. "Key": "testing /123",
  1397. "Bucket": "my/bucket"
  1398. },
  1399. "serialized": {
  1400. "method": "GET",
  1401. "body": "",
  1402. "uri": "/my%2Fbucket/testing%20/123"
  1403. }
  1404. }
  1405. ]
  1406. },
  1407. {
  1408. "description": "Omits null query params, but serializes empty strings",
  1409. "metadata": {
  1410. "protocol": "rest-xml",
  1411. "apiVersion": "2014-01-01"
  1412. },
  1413. "shapes": {
  1414. "InputShape": {
  1415. "type": "structure",
  1416. "members": {
  1417. "foo": {
  1418. "location":"querystring",
  1419. "locationName":"param-name",
  1420. "shape": "Foo"
  1421. }
  1422. }
  1423. },
  1424. "Foo": {
  1425. "type": "string"
  1426. }
  1427. },
  1428. "cases": [
  1429. {
  1430. "given": {
  1431. "name": "OperationName",
  1432. "http": {
  1433. "method": "POST",
  1434. "requestUri": "/path"
  1435. },
  1436. "input": { "shape": "InputShape" }
  1437. },
  1438. "params": { "foo": null },
  1439. "serialized": {
  1440. "method": "POST",
  1441. "body": "",
  1442. "uri": "/path"
  1443. }
  1444. },
  1445. {
  1446. "given": {
  1447. "name": "OperationName",
  1448. "http": {
  1449. "method": "POST",
  1450. "requestUri": "/path?abc=mno"
  1451. },
  1452. "input": { "shape": "InputShape" }
  1453. },
  1454. "params": { "foo": "" },
  1455. "serialized": {
  1456. "method": "POST",
  1457. "body": "",
  1458. "uri": "/path?abc=mno&param-name="
  1459. }
  1460. }
  1461. ]
  1462. },
  1463. {
  1464. "description": "Recursive shapes",
  1465. "metadata": {
  1466. "protocol": "rest-xml",
  1467. "apiVersion": "2014-01-01"
  1468. },
  1469. "shapes": {
  1470. "InputShape": {
  1471. "type": "structure",
  1472. "members": {
  1473. "RecursiveStruct": {
  1474. "shape": "RecursiveStructType"
  1475. }
  1476. }
  1477. },
  1478. "RecursiveStructType": {
  1479. "type": "structure",
  1480. "members": {
  1481. "NoRecurse": {
  1482. "shape": "StringType"
  1483. },
  1484. "RecursiveStruct": {
  1485. "shape": "RecursiveStructType"
  1486. },
  1487. "RecursiveList": {
  1488. "shape": "RecursiveListType"
  1489. },
  1490. "RecursiveMap": {
  1491. "shape": "RecursiveMapType"
  1492. }
  1493. }
  1494. },
  1495. "RecursiveListType": {
  1496. "type": "list",
  1497. "member": {
  1498. "shape": "RecursiveStructType"
  1499. }
  1500. },
  1501. "RecursiveMapType": {
  1502. "type": "map",
  1503. "key": {
  1504. "shape": "StringType"
  1505. },
  1506. "value": {
  1507. "shape": "RecursiveStructType"
  1508. }
  1509. },
  1510. "StringType": {
  1511. "type": "string"
  1512. }
  1513. },
  1514. "cases": [
  1515. {
  1516. "given": {
  1517. "input": {
  1518. "shape": "InputShape",
  1519. "locationName": "OperationRequest",
  1520. "xmlNamespace": {"uri": "https://foo/"}
  1521. },
  1522. "http": {
  1523. "method": "POST",
  1524. "requestUri": "/path"
  1525. },
  1526. "name": "OperationName"
  1527. },
  1528. "params": {
  1529. "RecursiveStruct": {
  1530. "NoRecurse": "foo"
  1531. }
  1532. },
  1533. "serialized": {
  1534. "uri": "/path",
  1535. "body": "<OperationRequest xmlns=\"https://foo/\"><RecursiveStruct><NoRecurse>foo</NoRecurse></RecursiveStruct></OperationRequest>"
  1536. }
  1537. },
  1538. {
  1539. "given": {
  1540. "input": {
  1541. "shape": "InputShape",
  1542. "locationName": "OperationRequest",
  1543. "xmlNamespace": {"uri": "https://foo/"}
  1544. },
  1545. "http": {
  1546. "method": "POST",
  1547. "requestUri": "/path"
  1548. },
  1549. "name": "OperationName"
  1550. },
  1551. "params": {
  1552. "RecursiveStruct": {
  1553. "RecursiveStruct": {
  1554. "NoRecurse": "foo"
  1555. }
  1556. }
  1557. },
  1558. "serialized": {
  1559. "uri": "/path",
  1560. "body": "<OperationRequest xmlns=\"https://foo/\"><RecursiveStruct><RecursiveStruct><NoRecurse>foo</NoRecurse></RecursiveStruct></RecursiveStruct></OperationRequest>"
  1561. }
  1562. },
  1563. {
  1564. "given": {
  1565. "input": {
  1566. "shape": "InputShape",
  1567. "locationName": "OperationRequest",
  1568. "xmlNamespace": {"uri": "https://foo/"}
  1569. },
  1570. "http": {
  1571. "method": "POST",
  1572. "requestUri": "/path"
  1573. },
  1574. "name": "OperationName"
  1575. },
  1576. "params": {
  1577. "RecursiveStruct": {
  1578. "RecursiveStruct": {
  1579. "RecursiveStruct": {
  1580. "RecursiveStruct": {
  1581. "NoRecurse": "foo"
  1582. }
  1583. }
  1584. }
  1585. }
  1586. },
  1587. "serialized": {
  1588. "uri": "/path",
  1589. "body": "<OperationRequest xmlns=\"https://foo/\"><RecursiveStruct><RecursiveStruct><RecursiveStruct><RecursiveStruct><NoRecurse>foo</NoRecurse></RecursiveStruct></RecursiveStruct></RecursiveStruct></RecursiveStruct></OperationRequest>"
  1590. }
  1591. },
  1592. {
  1593. "given": {
  1594. "input": {
  1595. "shape": "InputShape",
  1596. "locationName": "OperationRequest",
  1597. "xmlNamespace": {"uri": "https://foo/"}
  1598. },
  1599. "http": {
  1600. "method": "POST",
  1601. "requestUri": "/path"
  1602. },
  1603. "name": "OperationName"
  1604. },
  1605. "params": {
  1606. "RecursiveStruct": {
  1607. "RecursiveList": [
  1608. {
  1609. "NoRecurse": "foo"
  1610. },
  1611. {
  1612. "NoRecurse": "bar"
  1613. }
  1614. ]
  1615. }
  1616. },
  1617. "serialized": {
  1618. "uri": "/path",
  1619. "body": "<OperationRequest xmlns=\"https://foo/\"><RecursiveStruct><RecursiveList><member><NoRecurse>foo</NoRecurse></member><member><NoRecurse>bar</NoRecurse></member></RecursiveList></RecursiveStruct></OperationRequest>"
  1620. }
  1621. },
  1622. {
  1623. "given": {
  1624. "input": {
  1625. "shape": "InputShape",
  1626. "locationName": "OperationRequest",
  1627. "xmlNamespace": {"uri": "https://foo/"}
  1628. },
  1629. "http": {
  1630. "method": "POST",
  1631. "requestUri": "/path"
  1632. },
  1633. "name": "OperationName"
  1634. },
  1635. "params": {
  1636. "RecursiveStruct": {
  1637. "RecursiveList": [
  1638. {
  1639. "NoRecurse": "foo"
  1640. },
  1641. {
  1642. "RecursiveStruct": {
  1643. "NoRecurse": "bar"
  1644. }
  1645. }
  1646. ]
  1647. }
  1648. },
  1649. "serialized": {
  1650. "uri": "/path",
  1651. "body": "<OperationRequest xmlns=\"https://foo/\"><RecursiveStruct><RecursiveList><member><NoRecurse>foo</NoRecurse></member><member><RecursiveStruct><NoRecurse>bar</NoRecurse></RecursiveStruct></member></RecursiveList></RecursiveStruct></OperationRequest>"
  1652. }
  1653. },
  1654. {
  1655. "given": {
  1656. "input": {
  1657. "shape": "InputShape",
  1658. "locationName": "OperationRequest",
  1659. "xmlNamespace": {"uri": "https://foo/"}
  1660. },
  1661. "http": {
  1662. "method": "POST",
  1663. "requestUri": "/path"
  1664. },
  1665. "name": "OperationName"
  1666. },
  1667. "params": {
  1668. "RecursiveStruct": {
  1669. "RecursiveMap": {
  1670. "foo": {
  1671. "NoRecurse": "foo"
  1672. },
  1673. "bar": {
  1674. "NoRecurse": "bar"
  1675. }
  1676. }
  1677. }
  1678. },
  1679. "serialized": {
  1680. "uri": "/path",
  1681. "body": "<OperationRequest xmlns=\"https://foo/\"><RecursiveStruct><RecursiveMap><entry><key>foo</key><value><NoRecurse>foo</NoRecurse></value></entry><entry><key>bar</key><value><NoRecurse>bar</NoRecurse></value></entry></RecursiveMap></RecursiveStruct></OperationRequest>"
  1682. }
  1683. }
  1684. ]
  1685. },
  1686. {
  1687. "description": "Idempotency token auto fill",
  1688. "metadata": {
  1689. "protocol": "rest-xml",
  1690. "apiVersion": "2014-01-01"
  1691. },
  1692. "shapes": {
  1693. "InputShape": {
  1694. "type": "structure",
  1695. "members": {
  1696. "Token": {
  1697. "shape": "StringType",
  1698. "idempotencyToken": true
  1699. }
  1700. }
  1701. },
  1702. "StringType": {
  1703. "type": "string"
  1704. }
  1705. },
  1706. "cases": [
  1707. {
  1708. "given": {
  1709. "input": {
  1710. "shape": "InputShape"
  1711. },
  1712. "http": {
  1713. "method": "POST",
  1714. "requestUri": "/path"
  1715. },
  1716. "name": "OperationName"
  1717. },
  1718. "params": {
  1719. "Token": "abc123"
  1720. },
  1721. "serialized": {
  1722. "uri": "/path",
  1723. "headers": {},
  1724. "body": "<InputShape><Token>abc123</Token></InputShape>"
  1725. }
  1726. },
  1727. {
  1728. "given": {
  1729. "input": {
  1730. "shape": "InputShape"
  1731. },
  1732. "http": {
  1733. "method": "POST",
  1734. "requestUri": "/path"
  1735. },
  1736. "name": "OperationName"
  1737. },
  1738. "params": {
  1739. },
  1740. "serialized": {
  1741. "uri": "/path",
  1742. "headers": {},
  1743. "body": "<InputShape><Token>00000000-0000-4000-8000-000000000000</Token></InputShape>"
  1744. }
  1745. }
  1746. ]
  1747. },
  1748. {
  1749. "description": "Enum",
  1750. "metadata": {
  1751. "protocol": "rest-xml",
  1752. "apiVersion": "2014-01-01"
  1753. },
  1754. "shapes": {
  1755. "InputShape": {
  1756. "type": "structure",
  1757. "required": [
  1758. "URIFooEnum"
  1759. ],
  1760. "members": {
  1761. "HeaderEnum": {
  1762. "shape": "EnumType",
  1763. "location": "header",
  1764. "locationName": "x-amz-enum"
  1765. },
  1766. "FooEnum": {
  1767. "shape": "EnumType"
  1768. },
  1769. "URIFooEnum": {
  1770. "shape": "EnumType",
  1771. "location": "uri",
  1772. "locationName": "URIEnum"
  1773. },
  1774. "ListEnums": {
  1775. "shape": "EnumList"
  1776. },
  1777. "URIListEnums": {
  1778. "shape": "EnumList",
  1779. "location": "querystring",
  1780. "locationName": "ListEnums"
  1781. }
  1782. }
  1783. },
  1784. "EnumType":{
  1785. "type":"string",
  1786. "enum":[
  1787. "foo",
  1788. "bar",
  1789. "0",
  1790. "1"
  1791. ]
  1792. },
  1793. "EnumList":{
  1794. "type":"list",
  1795. "member": {"shape": "EnumType"}
  1796. }
  1797. },
  1798. "cases": [
  1799. {
  1800. "given": {
  1801. "input": {
  1802. "shape": "InputShape"
  1803. },
  1804. "http": {
  1805. "method": "POST",
  1806. "requestUri": "/Enum/{URIEnum}"
  1807. },
  1808. "name": "OperationName"
  1809. },
  1810. "params": {
  1811. "HeaderEnum": "baz",
  1812. "FooEnum": "foo",
  1813. "URIFooEnum": "bar",
  1814. "ListEnums": ["foo", "", "bar"],
  1815. "URIListEnums": ["0", "", "1"]
  1816. },
  1817. "serialized": {
  1818. "uri": "/Enum/bar?ListEnums=0&ListEnums=&ListEnums=1",
  1819. "headers": {"x-amz-enum": "baz"},
  1820. "body": "<InputShape><FooEnum>foo</FooEnum><ListEnums><member>foo</member><member></member><member>bar</member></ListEnums></InputShape>"
  1821. }
  1822. },
  1823. {
  1824. "given": {
  1825. "input": {
  1826. "shape": "InputShape"
  1827. },
  1828. "http": {
  1829. "method": "POST",
  1830. "requestUri": "/Enum/{URIEnum}"
  1831. },
  1832. "name": "OperationName"
  1833. },
  1834. "params": {
  1835. "URIFooEnum": "bar"
  1836. },
  1837. "serialized": {
  1838. "uri": "/Enum/bar",
  1839. "headers": {}
  1840. }
  1841. }
  1842. ]
  1843. },
  1844. {
  1845. "description": "Endpoint host trait",
  1846. "metadata": {
  1847. "protocol": "rest-xml",
  1848. "apiVersion": "2014-01-01"
  1849. },
  1850. "clientEndpoint": "https://service.region.amazonaws.com",
  1851. "shapes": {
  1852. "StaticInputShape": {
  1853. "type": "structure",
  1854. "members": {
  1855. "Name": {
  1856. "shape": "StringType"
  1857. }
  1858. }
  1859. },
  1860. "MemberRefInputShape": {
  1861. "type": "structure",
  1862. "members": {
  1863. "Name": {
  1864. "shape": "StringType",
  1865. "hostLabel": true
  1866. }
  1867. }
  1868. },
  1869. "StringType": {
  1870. "type": "string"
  1871. }
  1872. },
  1873. "cases": [
  1874. {
  1875. "given": {
  1876. "name": "StaticOp",
  1877. "input": {
  1878. "shape": "StaticInputShape",
  1879. "locationName": "StaticOpRequest"
  1880. },
  1881. "http": {
  1882. "method": "POST",
  1883. "requestUri": "/path"
  1884. },
  1885. "endpoint":{
  1886. "hostPrefix": "data-"
  1887. }
  1888. },
  1889. "params": {
  1890. "Name": "myname"
  1891. },
  1892. "serialized": {
  1893. "uri": "/path",
  1894. "body": "<StaticOpRequest><Name>myname</Name></StaticOpRequest>",
  1895. "host": "data-service.region.amazonaws.com"
  1896. }
  1897. },
  1898. {
  1899. "given": {
  1900. "name": "MemberRefOp",
  1901. "input": {
  1902. "shape": "MemberRefInputShape",
  1903. "locationName": "MemberRefOpRequest"
  1904. },
  1905. "http": {
  1906. "method": "GET",
  1907. "requestUri": "/path"
  1908. },
  1909. "endpoint":{
  1910. "hostPrefix": "foo-{Name}."
  1911. }
  1912. },
  1913. "params": {
  1914. "Name": "myname"
  1915. },
  1916. "serialized": {
  1917. "uri": "/path",
  1918. "body": "<MemberRefOpRequest><Name>myname</Name></MemberRefOpRequest>",
  1919. "host": "foo-myname.service.region.amazonaws.com"
  1920. }
  1921. }
  1922. ]
  1923. }
  1924. ]