api-2.json 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667
  1. {
  2. "metadata":{
  3. "apiVersion":"2014-11-11",
  4. "endpointPrefix":"lambda",
  5. "serviceFullName":"AWS Lambda",
  6. "signatureVersion":"v4",
  7. "protocol":"rest-json"
  8. },
  9. "operations":{
  10. "AddEventSource":{
  11. "name":"AddEventSource",
  12. "http":{
  13. "method":"POST",
  14. "requestUri":"/2014-11-13/event-source-mappings/"
  15. },
  16. "input":{"shape":"AddEventSourceRequest"},
  17. "output":{"shape":"EventSourceConfiguration"},
  18. "errors":[
  19. {
  20. "shape":"ServiceException",
  21. "error":{"httpStatusCode":500},
  22. "exception":true
  23. },
  24. {
  25. "shape":"InvalidParameterValueException",
  26. "error":{"httpStatusCode":400},
  27. "exception":true
  28. }
  29. ]
  30. },
  31. "DeleteFunction":{
  32. "name":"DeleteFunction",
  33. "http":{
  34. "method":"DELETE",
  35. "requestUri":"/2014-11-13/functions/{FunctionName}",
  36. "responseCode":204
  37. },
  38. "input":{"shape":"DeleteFunctionRequest"},
  39. "errors":[
  40. {
  41. "shape":"ServiceException",
  42. "error":{"httpStatusCode":500},
  43. "exception":true
  44. },
  45. {
  46. "shape":"ResourceNotFoundException",
  47. "error":{"httpStatusCode":404},
  48. "exception":true
  49. }
  50. ]
  51. },
  52. "GetEventSource":{
  53. "name":"GetEventSource",
  54. "http":{
  55. "method":"GET",
  56. "requestUri":"/2014-11-13/event-source-mappings/{UUID}",
  57. "responseCode":200
  58. },
  59. "input":{"shape":"GetEventSourceRequest"},
  60. "output":{"shape":"EventSourceConfiguration"},
  61. "errors":[
  62. {
  63. "shape":"ServiceException",
  64. "error":{"httpStatusCode":500},
  65. "exception":true
  66. },
  67. {
  68. "shape":"ResourceNotFoundException",
  69. "error":{"httpStatusCode":404},
  70. "exception":true
  71. },
  72. {
  73. "shape":"InvalidParameterValueException",
  74. "error":{"httpStatusCode":400},
  75. "exception":true
  76. }
  77. ]
  78. },
  79. "GetFunction":{
  80. "name":"GetFunction",
  81. "http":{
  82. "method":"GET",
  83. "requestUri":"/2014-11-13/functions/{FunctionName}",
  84. "responseCode":200
  85. },
  86. "input":{"shape":"GetFunctionRequest"},
  87. "output":{"shape":"GetFunctionResponse"},
  88. "errors":[
  89. {
  90. "shape":"ServiceException",
  91. "error":{"httpStatusCode":500},
  92. "exception":true
  93. },
  94. {
  95. "shape":"ResourceNotFoundException",
  96. "error":{"httpStatusCode":404},
  97. "exception":true
  98. }
  99. ]
  100. },
  101. "GetFunctionConfiguration":{
  102. "name":"GetFunctionConfiguration",
  103. "http":{
  104. "method":"GET",
  105. "requestUri":"/2014-11-13/functions/{FunctionName}/configuration",
  106. "responseCode":200
  107. },
  108. "input":{"shape":"GetFunctionConfigurationRequest"},
  109. "output":{"shape":"FunctionConfiguration"},
  110. "errors":[
  111. {
  112. "shape":"ServiceException",
  113. "error":{"httpStatusCode":500},
  114. "exception":true
  115. },
  116. {
  117. "shape":"ResourceNotFoundException",
  118. "error":{"httpStatusCode":404},
  119. "exception":true
  120. }
  121. ]
  122. },
  123. "InvokeAsync":{
  124. "name":"InvokeAsync",
  125. "http":{
  126. "method":"POST",
  127. "requestUri":"/2014-11-13/functions/{FunctionName}/invoke-async/",
  128. "responseCode":202
  129. },
  130. "input":{"shape":"InvokeAsyncRequest"},
  131. "output":{"shape":"InvokeAsyncResponse"},
  132. "errors":[
  133. {
  134. "shape":"ServiceException",
  135. "error":{"httpStatusCode":500},
  136. "exception":true
  137. },
  138. {
  139. "shape":"ResourceNotFoundException",
  140. "error":{"httpStatusCode":404},
  141. "exception":true
  142. },
  143. {
  144. "shape":"InvalidRequestContentException",
  145. "error":{"httpStatusCode":400},
  146. "exception":true
  147. }
  148. ]
  149. },
  150. "ListEventSources":{
  151. "name":"ListEventSources",
  152. "http":{
  153. "method":"GET",
  154. "requestUri":"/2014-11-13/event-source-mappings/",
  155. "responseCode":200
  156. },
  157. "input":{"shape":"ListEventSourcesRequest"},
  158. "output":{"shape":"ListEventSourcesResponse"},
  159. "errors":[
  160. {
  161. "shape":"ServiceException",
  162. "error":{"httpStatusCode":500},
  163. "exception":true
  164. },
  165. {
  166. "shape":"ResourceNotFoundException",
  167. "error":{"httpStatusCode":404},
  168. "exception":true
  169. },
  170. {
  171. "shape":"InvalidParameterValueException",
  172. "error":{"httpStatusCode":400},
  173. "exception":true
  174. }
  175. ]
  176. },
  177. "ListFunctions":{
  178. "name":"ListFunctions",
  179. "http":{
  180. "method":"GET",
  181. "requestUri":"/2014-11-13/functions/",
  182. "responseCode":200
  183. },
  184. "input":{"shape":"ListFunctionsRequest"},
  185. "output":{"shape":"ListFunctionsResponse"},
  186. "errors":[
  187. {
  188. "shape":"ServiceException",
  189. "error":{"httpStatusCode":500},
  190. "exception":true
  191. }
  192. ]
  193. },
  194. "RemoveEventSource":{
  195. "name":"RemoveEventSource",
  196. "http":{
  197. "method":"DELETE",
  198. "requestUri":"/2014-11-13/event-source-mappings/{UUID}",
  199. "responseCode":204
  200. },
  201. "input":{"shape":"RemoveEventSourceRequest"},
  202. "errors":[
  203. {
  204. "shape":"ServiceException",
  205. "error":{"httpStatusCode":500},
  206. "exception":true
  207. },
  208. {
  209. "shape":"ResourceNotFoundException",
  210. "error":{"httpStatusCode":404},
  211. "exception":true
  212. },
  213. {
  214. "shape":"InvalidParameterValueException",
  215. "error":{"httpStatusCode":400},
  216. "exception":true
  217. }
  218. ]
  219. },
  220. "UpdateFunctionConfiguration":{
  221. "name":"UpdateFunctionConfiguration",
  222. "http":{
  223. "method":"PUT",
  224. "requestUri":"/2014-11-13/functions/{FunctionName}/configuration",
  225. "responseCode":200
  226. },
  227. "input":{"shape":"UpdateFunctionConfigurationRequest"},
  228. "output":{"shape":"FunctionConfiguration"},
  229. "errors":[
  230. {
  231. "shape":"ServiceException",
  232. "error":{"httpStatusCode":500},
  233. "exception":true
  234. },
  235. {
  236. "shape":"ResourceNotFoundException",
  237. "error":{"httpStatusCode":404},
  238. "exception":true
  239. },
  240. {
  241. "shape":"InvalidParameterValueException",
  242. "error":{"httpStatusCode":400},
  243. "exception":true
  244. }
  245. ]
  246. },
  247. "UploadFunction":{
  248. "name":"UploadFunction",
  249. "http":{
  250. "method":"PUT",
  251. "requestUri":"/2014-11-13/functions/{FunctionName}",
  252. "responseCode":201
  253. },
  254. "input":{"shape":"UploadFunctionRequest"},
  255. "output":{"shape":"FunctionConfiguration"},
  256. "errors":[
  257. {
  258. "shape":"ServiceException",
  259. "error":{"httpStatusCode":500},
  260. "exception":true
  261. },
  262. {
  263. "shape":"InvalidParameterValueException",
  264. "error":{"httpStatusCode":400},
  265. "exception":true
  266. },
  267. {
  268. "shape":"ResourceNotFoundException",
  269. "error":{"httpStatusCode":404},
  270. "exception":true
  271. }
  272. ]
  273. }
  274. },
  275. "shapes":{
  276. "AddEventSourceRequest":{
  277. "type":"structure",
  278. "required":[
  279. "EventSource",
  280. "FunctionName",
  281. "Role"
  282. ],
  283. "members":{
  284. "EventSource":{"shape":"String"},
  285. "FunctionName":{"shape":"FunctionName"},
  286. "Role":{"shape":"RoleArn"},
  287. "BatchSize":{"shape":"Integer"},
  288. "Parameters":{"shape":"Map"}
  289. }
  290. },
  291. "Blob":{
  292. "type":"blob",
  293. "streaming":true
  294. },
  295. "DeleteFunctionRequest":{
  296. "type":"structure",
  297. "required":["FunctionName"],
  298. "members":{
  299. "FunctionName":{
  300. "shape":"FunctionName",
  301. "location":"uri",
  302. "locationName":"FunctionName"
  303. }
  304. }
  305. },
  306. "Description":{
  307. "type":"string",
  308. "min":0,
  309. "max":256
  310. },
  311. "EventSourceConfiguration":{
  312. "type":"structure",
  313. "members":{
  314. "UUID":{"shape":"String"},
  315. "BatchSize":{"shape":"Integer"},
  316. "EventSource":{"shape":"String"},
  317. "FunctionName":{"shape":"FunctionName"},
  318. "Parameters":{"shape":"Map"},
  319. "Role":{"shape":"RoleArn"},
  320. "LastModified":{"shape":"Timestamp"},
  321. "IsActive":{"shape":"Boolean"},
  322. "Status":{"shape":"String"}
  323. }
  324. },
  325. "EventSourceList":{
  326. "type":"list",
  327. "member":{"shape":"EventSourceConfiguration"}
  328. },
  329. "FunctionArn":{
  330. "type":"string",
  331. "pattern":"arn:aws:lambda:[a-z]{2}-[a-z]+-\\d{1}:\\d{12}:function:[a-zA-Z0-9-_]+(\\/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})?"
  332. },
  333. "FunctionCodeLocation":{
  334. "type":"structure",
  335. "members":{
  336. "RepositoryType":{"shape":"String"},
  337. "Location":{"shape":"String"}
  338. }
  339. },
  340. "FunctionConfiguration":{
  341. "type":"structure",
  342. "members":{
  343. "FunctionName":{"shape":"FunctionName"},
  344. "FunctionARN":{"shape":"FunctionArn"},
  345. "ConfigurationId":{"shape":"String"},
  346. "Runtime":{"shape":"Runtime"},
  347. "Role":{"shape":"RoleArn"},
  348. "Handler":{"shape":"Handler"},
  349. "Mode":{"shape":"Mode"},
  350. "CodeSize":{"shape":"Long"},
  351. "Description":{"shape":"Description"},
  352. "Timeout":{"shape":"Timeout"},
  353. "MemorySize":{"shape":"MemorySize"},
  354. "LastModified":{"shape":"Timestamp"}
  355. }
  356. },
  357. "FunctionList":{
  358. "type":"list",
  359. "member":{"shape":"FunctionConfiguration"}
  360. },
  361. "FunctionName":{
  362. "type":"string",
  363. "min":1,
  364. "max":64,
  365. "pattern":"[a-zA-Z0-9-_]+"
  366. },
  367. "GetEventSourceRequest":{
  368. "type":"structure",
  369. "required":["UUID"],
  370. "members":{
  371. "UUID":{
  372. "shape":"String",
  373. "location":"uri",
  374. "locationName":"UUID"
  375. }
  376. }
  377. },
  378. "GetFunctionConfigurationRequest":{
  379. "type":"structure",
  380. "required":["FunctionName"],
  381. "members":{
  382. "FunctionName":{
  383. "shape":"FunctionName",
  384. "location":"uri",
  385. "locationName":"FunctionName"
  386. }
  387. }
  388. },
  389. "GetFunctionRequest":{
  390. "type":"structure",
  391. "required":["FunctionName"],
  392. "members":{
  393. "FunctionName":{
  394. "shape":"FunctionName",
  395. "location":"uri",
  396. "locationName":"FunctionName"
  397. }
  398. }
  399. },
  400. "GetFunctionResponse":{
  401. "type":"structure",
  402. "members":{
  403. "Configuration":{"shape":"FunctionConfiguration"},
  404. "Code":{"shape":"FunctionCodeLocation"}
  405. }
  406. },
  407. "Handler":{
  408. "type":"string",
  409. "pattern":"[a-zA-Z0-9./\\-_]+"
  410. },
  411. "HttpStatus":{"type":"integer"},
  412. "Integer":{"type":"integer"},
  413. "InvalidParameterValueException":{
  414. "type":"structure",
  415. "members":{
  416. "Type":{"shape":"String"},
  417. "message":{"shape":"String"}
  418. },
  419. "error":{"httpStatusCode":400},
  420. "exception":true
  421. },
  422. "InvalidRequestContentException":{
  423. "type":"structure",
  424. "members":{
  425. "Type":{"shape":"String"},
  426. "message":{"shape":"String"}
  427. },
  428. "error":{"httpStatusCode":400},
  429. "exception":true
  430. },
  431. "InvokeAsyncRequest":{
  432. "type":"structure",
  433. "required":[
  434. "FunctionName",
  435. "InvokeArgs"
  436. ],
  437. "members":{
  438. "FunctionName":{
  439. "shape":"FunctionName",
  440. "location":"uri",
  441. "locationName":"FunctionName"
  442. },
  443. "InvokeArgs":{"shape":"Blob"}
  444. },
  445. "payload":"InvokeArgs"
  446. },
  447. "InvokeAsyncResponse":{
  448. "type":"structure",
  449. "members":{
  450. "Status":{
  451. "shape":"HttpStatus",
  452. "location":"statusCode"
  453. }
  454. }
  455. },
  456. "ListEventSourcesRequest":{
  457. "type":"structure",
  458. "members":{
  459. "EventSourceArn":{
  460. "shape":"String",
  461. "location":"querystring",
  462. "locationName":"EventSource"
  463. },
  464. "FunctionName":{
  465. "shape":"FunctionName",
  466. "location":"querystring",
  467. "locationName":"FunctionName"
  468. },
  469. "Marker":{
  470. "shape":"String",
  471. "location":"querystring",
  472. "locationName":"Marker"
  473. },
  474. "MaxItems":{
  475. "shape":"MaxListItems",
  476. "location":"querystring",
  477. "locationName":"MaxItems"
  478. }
  479. }
  480. },
  481. "ListEventSourcesResponse":{
  482. "type":"structure",
  483. "members":{
  484. "NextMarker":{"shape":"String"},
  485. "EventSources":{"shape":"EventSourceList"}
  486. }
  487. },
  488. "ListFunctionsRequest":{
  489. "type":"structure",
  490. "members":{
  491. "Marker":{
  492. "shape":"String",
  493. "location":"querystring",
  494. "locationName":"Marker"
  495. },
  496. "MaxItems":{
  497. "shape":"MaxListItems",
  498. "location":"querystring",
  499. "locationName":"MaxItems"
  500. }
  501. }
  502. },
  503. "ListFunctionsResponse":{
  504. "type":"structure",
  505. "members":{
  506. "NextMarker":{"shape":"String"},
  507. "Functions":{"shape":"FunctionList"}
  508. }
  509. },
  510. "Long":{"type":"long"},
  511. "Map":{
  512. "type":"map",
  513. "key":{"shape":"String"},
  514. "value":{"shape":"String"}
  515. },
  516. "MaxListItems":{
  517. "type":"integer",
  518. "min":1,
  519. "max":10000
  520. },
  521. "MemorySize":{
  522. "type":"integer",
  523. "min":128,
  524. "max":1024
  525. },
  526. "Mode":{
  527. "type":"string",
  528. "enum":["event"]
  529. },
  530. "RemoveEventSourceRequest":{
  531. "type":"structure",
  532. "required":["UUID"],
  533. "members":{
  534. "UUID":{
  535. "shape":"String",
  536. "location":"uri",
  537. "locationName":"UUID"
  538. }
  539. }
  540. },
  541. "ResourceNotFoundException":{
  542. "type":"structure",
  543. "members":{
  544. "Type":{"shape":"String"},
  545. "Message":{"shape":"String"}
  546. },
  547. "error":{"httpStatusCode":404},
  548. "exception":true
  549. },
  550. "RoleArn":{
  551. "type":"string",
  552. "pattern":"arn:aws:iam::\\d{12}:role/?[a-zA-Z_0-9+=,.@\\-_/]+"
  553. },
  554. "Runtime":{
  555. "type":"string",
  556. "enum":["nodejs"]
  557. },
  558. "ServiceException":{
  559. "type":"structure",
  560. "members":{
  561. "Type":{"shape":"String"},
  562. "Message":{"shape":"String"}
  563. },
  564. "error":{"httpStatusCode":500},
  565. "exception":true
  566. },
  567. "String":{"type":"string"},
  568. "Timeout":{
  569. "type":"integer",
  570. "min":1,
  571. "max":60
  572. },
  573. "Timestamp":{"type":"string"},
  574. "UpdateFunctionConfigurationRequest":{
  575. "type":"structure",
  576. "required":["FunctionName"],
  577. "members":{
  578. "FunctionName":{
  579. "shape":"FunctionName",
  580. "location":"uri",
  581. "locationName":"FunctionName"
  582. },
  583. "Role":{
  584. "shape":"RoleArn",
  585. "location":"querystring",
  586. "locationName":"Role"
  587. },
  588. "Handler":{
  589. "shape":"Handler",
  590. "location":"querystring",
  591. "locationName":"Handler"
  592. },
  593. "Description":{
  594. "shape":"Description",
  595. "location":"querystring",
  596. "locationName":"Description"
  597. },
  598. "Timeout":{
  599. "shape":"Timeout",
  600. "location":"querystring",
  601. "locationName":"Timeout"
  602. },
  603. "MemorySize":{
  604. "shape":"MemorySize",
  605. "location":"querystring",
  606. "locationName":"MemorySize"
  607. }
  608. }
  609. },
  610. "UploadFunctionRequest":{
  611. "type":"structure",
  612. "required":[
  613. "FunctionName",
  614. "FunctionZip",
  615. "Runtime",
  616. "Role",
  617. "Handler",
  618. "Mode"
  619. ],
  620. "members":{
  621. "FunctionName":{
  622. "shape":"FunctionName",
  623. "location":"uri",
  624. "locationName":"FunctionName"
  625. },
  626. "FunctionZip":{"shape":"Blob"},
  627. "Runtime":{
  628. "shape":"Runtime",
  629. "location":"querystring",
  630. "locationName":"Runtime"
  631. },
  632. "Role":{
  633. "shape":"RoleArn",
  634. "location":"querystring",
  635. "locationName":"Role"
  636. },
  637. "Handler":{
  638. "shape":"Handler",
  639. "location":"querystring",
  640. "locationName":"Handler"
  641. },
  642. "Mode":{
  643. "shape":"Mode",
  644. "location":"querystring",
  645. "locationName":"Mode"
  646. },
  647. "Description":{
  648. "shape":"Description",
  649. "location":"querystring",
  650. "locationName":"Description"
  651. },
  652. "Timeout":{
  653. "shape":"Timeout",
  654. "location":"querystring",
  655. "locationName":"Timeout"
  656. },
  657. "MemorySize":{
  658. "shape":"MemorySize",
  659. "location":"querystring",
  660. "locationName":"MemorySize"
  661. }
  662. },
  663. "payload":"FunctionZip"
  664. },
  665. "Boolean":{"type":"boolean"}
  666. }
  667. }