ec2.json 9.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454
  1. [
  2. {
  3. "description": "Scalar members",
  4. "metadata": {
  5. "protocol": "ec2"
  6. },
  7. "shapes": {
  8. "OutputShape": {
  9. "type": "structure",
  10. "members": {
  11. "Str": {
  12. "shape": "StringType"
  13. },
  14. "Num": {
  15. "shape": "IntegerType",
  16. "locationName": "FooNum"
  17. },
  18. "FalseBool": {
  19. "shape": "BooleanType"
  20. },
  21. "TrueBool": {
  22. "shape": "BooleanType"
  23. },
  24. "Float": {
  25. "shape": "FloatType"
  26. },
  27. "Double": {
  28. "shape": "DoubleType"
  29. },
  30. "Long": {
  31. "shape": "LongType"
  32. },
  33. "Char": {
  34. "shape": "CharType"
  35. }
  36. }
  37. },
  38. "StringType": {
  39. "type": "string"
  40. },
  41. "IntegerType": {
  42. "type": "integer"
  43. },
  44. "BooleanType": {
  45. "type": "boolean"
  46. },
  47. "FloatType": {
  48. "type": "float"
  49. },
  50. "DoubleType": {
  51. "type": "double"
  52. },
  53. "LongType": {
  54. "type": "long"
  55. },
  56. "CharType": {
  57. "type": "character"
  58. }
  59. },
  60. "cases": [
  61. {
  62. "given": {
  63. "output": {
  64. "shape": "OutputShape"
  65. },
  66. "name": "OperationName"
  67. },
  68. "result": {
  69. "Str": "myname",
  70. "Num": 123,
  71. "FalseBool": false,
  72. "TrueBool": true,
  73. "Float": 1.2,
  74. "Double": 1.3,
  75. "Long": 200,
  76. "Char": "a"
  77. },
  78. "response": {
  79. "status_code": 200,
  80. "headers": {},
  81. "body": "<OperationNameResponse><Str>myname</Str><FooNum>123</FooNum><FalseBool>false</FalseBool><TrueBool>true</TrueBool><Float>1.2</Float><Double>1.3</Double><Long>200</Long><Char>a</Char><RequestId>request-id</RequestId></OperationNameResponse>"
  82. }
  83. }
  84. ]
  85. },
  86. {
  87. "description": "Blob",
  88. "metadata": {
  89. "protocol": "ec2"
  90. },
  91. "shapes": {
  92. "OutputShape": {
  93. "type": "structure",
  94. "members": {
  95. "Blob": {
  96. "shape": "BlobType"
  97. }
  98. }
  99. },
  100. "BlobType": {
  101. "type": "blob"
  102. }
  103. },
  104. "cases": [
  105. {
  106. "given": {
  107. "output": {
  108. "shape": "OutputShape"
  109. },
  110. "name": "OperationName"
  111. },
  112. "result": {
  113. "Blob": "value"
  114. },
  115. "response": {
  116. "status_code": 200,
  117. "headers": {},
  118. "body": "<OperationNameResponse><Blob>dmFsdWU=</Blob><RequestId>requestid</RequestId></OperationNameResponse>"
  119. }
  120. }
  121. ]
  122. },
  123. {
  124. "description": "Lists",
  125. "metadata": {
  126. "protocol": "ec2"
  127. },
  128. "shapes": {
  129. "OutputShape": {
  130. "type": "structure",
  131. "members": {
  132. "ListMember": {
  133. "shape": "ListShape"
  134. }
  135. }
  136. },
  137. "ListShape": {
  138. "type": "list",
  139. "member": {
  140. "shape": "StringType"
  141. }
  142. },
  143. "StringType": {
  144. "type": "string"
  145. }
  146. },
  147. "cases": [
  148. {
  149. "given": {
  150. "output": {
  151. "shape": "OutputShape"
  152. },
  153. "name": "OperationName"
  154. },
  155. "result": {
  156. "ListMember": ["abc", "123"]
  157. },
  158. "response": {
  159. "status_code": 200,
  160. "headers": {},
  161. "body": "<OperationNameResponse><ListMember><member>abc</member><member>123</member></ListMember><RequestId>requestid</RequestId></OperationNameResponse>"
  162. }
  163. }
  164. ]
  165. },
  166. {
  167. "description": "List with custom member name",
  168. "metadata": {
  169. "protocol": "ec2"
  170. },
  171. "shapes": {
  172. "OutputShape": {
  173. "type": "structure",
  174. "members": {
  175. "ListMember": {
  176. "shape": "ListShape"
  177. }
  178. }
  179. },
  180. "ListShape": {
  181. "type": "list",
  182. "member": {
  183. "shape": "StringType",
  184. "locationName": "item"
  185. }
  186. },
  187. "StringType": {
  188. "type": "string"
  189. }
  190. },
  191. "cases": [
  192. {
  193. "given": {
  194. "output": {
  195. "shape": "OutputShape"
  196. },
  197. "name": "OperationName"
  198. },
  199. "result": {
  200. "ListMember": ["abc", "123"]
  201. },
  202. "response": {
  203. "status_code": 200,
  204. "headers": {},
  205. "body": "<OperationNameResponse><ListMember><item>abc</item><item>123</item></ListMember><RequestId>requestid</RequestId></OperationNameResponse>"
  206. }
  207. }
  208. ]
  209. },
  210. {
  211. "description": "Flattened List",
  212. "metadata": {
  213. "protocol": "ec2"
  214. },
  215. "shapes": {
  216. "OutputShape": {
  217. "type": "structure",
  218. "members": {
  219. "ListMember": {
  220. "shape": "ListType",
  221. "flattened": true
  222. }
  223. }
  224. },
  225. "ListType": {
  226. "type": "list",
  227. "member": {
  228. "shape": "StringType"
  229. }
  230. },
  231. "StringType": {
  232. "type": "string"
  233. }
  234. },
  235. "cases": [
  236. {
  237. "given": {
  238. "output": {
  239. "shape": "OutputShape"
  240. },
  241. "name": "OperationName"
  242. },
  243. "result": {
  244. "ListMember": ["abc", "123"]
  245. },
  246. "response": {
  247. "status_code": 200,
  248. "headers": {},
  249. "body": "<OperationNameResponse><ListMember>abc</ListMember><ListMember>123</ListMember><RequestId>requestid</RequestId></OperationNameResponse>"
  250. }
  251. }
  252. ]
  253. },
  254. {
  255. "description": "Normal map",
  256. "metadata": {
  257. "protocol": "ec2"
  258. },
  259. "shapes": {
  260. "OutputShape": {
  261. "type": "structure",
  262. "members": {
  263. "Map": {
  264. "shape": "MapType"
  265. }
  266. }
  267. },
  268. "MapType": {
  269. "type": "map",
  270. "key": {
  271. "shape": "StringType"
  272. },
  273. "value": {
  274. "shape": "StructureType"
  275. }
  276. },
  277. "StructureType": {
  278. "type": "structure",
  279. "members": {
  280. "foo": {
  281. "shape": "StringType"
  282. }
  283. }
  284. },
  285. "StringType": {
  286. "type": "string"
  287. }
  288. },
  289. "cases": [
  290. {
  291. "given": {
  292. "output": {
  293. "shape": "OutputShape"
  294. },
  295. "name": "OperationName"
  296. },
  297. "result": {
  298. "Map": {
  299. "qux": {
  300. "foo": "bar"
  301. },
  302. "baz": {
  303. "foo": "bam"
  304. }
  305. }
  306. },
  307. "response": {
  308. "status_code": 200,
  309. "headers": {},
  310. "body": "<OperationNameResponse><Map><entry><key>qux</key><value><foo>bar</foo></value></entry><entry><key>baz</key><value><foo>bam</foo></value></entry></Map><RequestId>requestid</RequestId></OperationNameResponse>"
  311. }
  312. }
  313. ]
  314. },
  315. {
  316. "description": "Flattened map",
  317. "metadata": {
  318. "protocol": "ec2"
  319. },
  320. "shapes": {
  321. "OutputShape": {
  322. "type": "structure",
  323. "members": {
  324. "Map": {
  325. "shape": "MapType",
  326. "flattened": true
  327. }
  328. }
  329. },
  330. "MapType": {
  331. "type": "map",
  332. "key": {
  333. "shape": "StringType"
  334. },
  335. "value": {
  336. "shape": "StringType"
  337. }
  338. },
  339. "StringType": {
  340. "type": "string"
  341. }
  342. },
  343. "cases": [
  344. {
  345. "given": {
  346. "output": {
  347. "shape": "OutputShape"
  348. },
  349. "name": "OperationName"
  350. },
  351. "result": {
  352. "Map": {
  353. "qux": "bar",
  354. "baz": "bam"
  355. }
  356. },
  357. "response": {
  358. "status_code": 200,
  359. "headers": {},
  360. "body": "<OperationNameResponse><Map><key>qux</key><value>bar</value></Map><Map><key>baz</key><value>bam</value></Map><RequestId>requestid</RequestId></OperationNameResponse>"
  361. }
  362. }
  363. ]
  364. },
  365. {
  366. "description": "Named map",
  367. "metadata": {
  368. "protocol": "ec2"
  369. },
  370. "shapes": {
  371. "OutputShape": {
  372. "type": "structure",
  373. "members": {
  374. "Map": {
  375. "shape": "MapType",
  376. "flattened": true
  377. }
  378. }
  379. },
  380. "MapType": {
  381. "type": "map",
  382. "key": {
  383. "shape": "StringType",
  384. "locationName": "foo"
  385. },
  386. "value": {
  387. "shape": "StringType",
  388. "locationName": "bar"
  389. }
  390. },
  391. "StringType": {
  392. "type": "string"
  393. }
  394. },
  395. "cases": [
  396. {
  397. "given": {
  398. "output": {
  399. "shape": "OutputShape"
  400. },
  401. "name": "OperationName"
  402. },
  403. "result": {
  404. "Map": {
  405. "qux": "bar",
  406. "baz": "bam"
  407. }
  408. },
  409. "response": {
  410. "status_code": 200,
  411. "headers": {},
  412. "body": "<OperationNameResponse><Map><foo>qux</foo><bar>bar</bar></Map><Map><foo>baz</foo><bar>bam</bar></Map><RequestId>requestid</RequestId></OperationNameResponse>"
  413. }
  414. }
  415. ]
  416. },
  417. {
  418. "description": "Empty string",
  419. "metadata": {
  420. "protocol": "ec2"
  421. },
  422. "shapes": {
  423. "OutputShape": {
  424. "type": "structure",
  425. "members": {
  426. "Foo": {
  427. "shape": "StringType"
  428. }
  429. }
  430. },
  431. "StringType": {
  432. "type": "string"
  433. }
  434. },
  435. "cases": [
  436. {
  437. "given": {
  438. "output": {
  439. "shape": "OutputShape"
  440. },
  441. "name": "OperationName"
  442. },
  443. "result": {
  444. "Foo": ""
  445. },
  446. "response": {
  447. "status_code": 200,
  448. "headers": {},
  449. "body": "<OperationNameResponse><Foo/><RequestId>requestid</RequestId></OperationNameResponse>"
  450. }
  451. }
  452. ]
  453. }
  454. ]