api.go 46 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478
  1. // THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
  2. // Package cloudwatch provides a client for Amazon CloudWatch.
  3. package cloudwatch
  4. import (
  5. "time"
  6. "github.com/aws/aws-sdk-go/aws/awsutil"
  7. "github.com/aws/aws-sdk-go/aws/request"
  8. )
  9. const opDeleteAlarms = "DeleteAlarms"
  10. // DeleteAlarmsRequest generates a request for the DeleteAlarms operation.
  11. func (c *CloudWatch) DeleteAlarmsRequest(input *DeleteAlarmsInput) (req *request.Request, output *DeleteAlarmsOutput) {
  12. op := &request.Operation{
  13. Name: opDeleteAlarms,
  14. HTTPMethod: "POST",
  15. HTTPPath: "/",
  16. }
  17. if input == nil {
  18. input = &DeleteAlarmsInput{}
  19. }
  20. req = c.newRequest(op, input, output)
  21. output = &DeleteAlarmsOutput{}
  22. req.Data = output
  23. return
  24. }
  25. // Deletes all specified alarms. In the event of an error, no alarms are deleted.
  26. func (c *CloudWatch) DeleteAlarms(input *DeleteAlarmsInput) (*DeleteAlarmsOutput, error) {
  27. req, out := c.DeleteAlarmsRequest(input)
  28. err := req.Send()
  29. return out, err
  30. }
  31. const opDescribeAlarmHistory = "DescribeAlarmHistory"
  32. // DescribeAlarmHistoryRequest generates a request for the DescribeAlarmHistory operation.
  33. func (c *CloudWatch) DescribeAlarmHistoryRequest(input *DescribeAlarmHistoryInput) (req *request.Request, output *DescribeAlarmHistoryOutput) {
  34. op := &request.Operation{
  35. Name: opDescribeAlarmHistory,
  36. HTTPMethod: "POST",
  37. HTTPPath: "/",
  38. Paginator: &request.Paginator{
  39. InputTokens: []string{"NextToken"},
  40. OutputTokens: []string{"NextToken"},
  41. LimitToken: "MaxRecords",
  42. TruncationToken: "",
  43. },
  44. }
  45. if input == nil {
  46. input = &DescribeAlarmHistoryInput{}
  47. }
  48. req = c.newRequest(op, input, output)
  49. output = &DescribeAlarmHistoryOutput{}
  50. req.Data = output
  51. return
  52. }
  53. // Retrieves history for the specified alarm. Filter alarms by date range or
  54. // item type. If an alarm name is not specified, Amazon CloudWatch returns histories
  55. // for all of the owner's alarms.
  56. func (c *CloudWatch) DescribeAlarmHistory(input *DescribeAlarmHistoryInput) (*DescribeAlarmHistoryOutput, error) {
  57. req, out := c.DescribeAlarmHistoryRequest(input)
  58. err := req.Send()
  59. return out, err
  60. }
  61. func (c *CloudWatch) DescribeAlarmHistoryPages(input *DescribeAlarmHistoryInput, fn func(p *DescribeAlarmHistoryOutput, lastPage bool) (shouldContinue bool)) error {
  62. page, _ := c.DescribeAlarmHistoryRequest(input)
  63. return page.EachPage(func(p interface{}, lastPage bool) bool {
  64. return fn(p.(*DescribeAlarmHistoryOutput), lastPage)
  65. })
  66. }
  67. const opDescribeAlarms = "DescribeAlarms"
  68. // DescribeAlarmsRequest generates a request for the DescribeAlarms operation.
  69. func (c *CloudWatch) DescribeAlarmsRequest(input *DescribeAlarmsInput) (req *request.Request, output *DescribeAlarmsOutput) {
  70. op := &request.Operation{
  71. Name: opDescribeAlarms,
  72. HTTPMethod: "POST",
  73. HTTPPath: "/",
  74. Paginator: &request.Paginator{
  75. InputTokens: []string{"NextToken"},
  76. OutputTokens: []string{"NextToken"},
  77. LimitToken: "MaxRecords",
  78. TruncationToken: "",
  79. },
  80. }
  81. if input == nil {
  82. input = &DescribeAlarmsInput{}
  83. }
  84. req = c.newRequest(op, input, output)
  85. output = &DescribeAlarmsOutput{}
  86. req.Data = output
  87. return
  88. }
  89. // Retrieves alarms with the specified names. If no name is specified, all alarms
  90. // for the user are returned. Alarms can be retrieved by using only a prefix
  91. // for the alarm name, the alarm state, or a prefix for any action.
  92. func (c *CloudWatch) DescribeAlarms(input *DescribeAlarmsInput) (*DescribeAlarmsOutput, error) {
  93. req, out := c.DescribeAlarmsRequest(input)
  94. err := req.Send()
  95. return out, err
  96. }
  97. func (c *CloudWatch) DescribeAlarmsPages(input *DescribeAlarmsInput, fn func(p *DescribeAlarmsOutput, lastPage bool) (shouldContinue bool)) error {
  98. page, _ := c.DescribeAlarmsRequest(input)
  99. return page.EachPage(func(p interface{}, lastPage bool) bool {
  100. return fn(p.(*DescribeAlarmsOutput), lastPage)
  101. })
  102. }
  103. const opDescribeAlarmsForMetric = "DescribeAlarmsForMetric"
  104. // DescribeAlarmsForMetricRequest generates a request for the DescribeAlarmsForMetric operation.
  105. func (c *CloudWatch) DescribeAlarmsForMetricRequest(input *DescribeAlarmsForMetricInput) (req *request.Request, output *DescribeAlarmsForMetricOutput) {
  106. op := &request.Operation{
  107. Name: opDescribeAlarmsForMetric,
  108. HTTPMethod: "POST",
  109. HTTPPath: "/",
  110. }
  111. if input == nil {
  112. input = &DescribeAlarmsForMetricInput{}
  113. }
  114. req = c.newRequest(op, input, output)
  115. output = &DescribeAlarmsForMetricOutput{}
  116. req.Data = output
  117. return
  118. }
  119. // Retrieves all alarms for a single metric. Specify a statistic, period, or
  120. // unit to filter the set of alarms further.
  121. func (c *CloudWatch) DescribeAlarmsForMetric(input *DescribeAlarmsForMetricInput) (*DescribeAlarmsForMetricOutput, error) {
  122. req, out := c.DescribeAlarmsForMetricRequest(input)
  123. err := req.Send()
  124. return out, err
  125. }
  126. const opDisableAlarmActions = "DisableAlarmActions"
  127. // DisableAlarmActionsRequest generates a request for the DisableAlarmActions operation.
  128. func (c *CloudWatch) DisableAlarmActionsRequest(input *DisableAlarmActionsInput) (req *request.Request, output *DisableAlarmActionsOutput) {
  129. op := &request.Operation{
  130. Name: opDisableAlarmActions,
  131. HTTPMethod: "POST",
  132. HTTPPath: "/",
  133. }
  134. if input == nil {
  135. input = &DisableAlarmActionsInput{}
  136. }
  137. req = c.newRequest(op, input, output)
  138. output = &DisableAlarmActionsOutput{}
  139. req.Data = output
  140. return
  141. }
  142. // Disables actions for the specified alarms. When an alarm's actions are disabled
  143. // the alarm's state may change, but none of the alarm's actions will execute.
  144. func (c *CloudWatch) DisableAlarmActions(input *DisableAlarmActionsInput) (*DisableAlarmActionsOutput, error) {
  145. req, out := c.DisableAlarmActionsRequest(input)
  146. err := req.Send()
  147. return out, err
  148. }
  149. const opEnableAlarmActions = "EnableAlarmActions"
  150. // EnableAlarmActionsRequest generates a request for the EnableAlarmActions operation.
  151. func (c *CloudWatch) EnableAlarmActionsRequest(input *EnableAlarmActionsInput) (req *request.Request, output *EnableAlarmActionsOutput) {
  152. op := &request.Operation{
  153. Name: opEnableAlarmActions,
  154. HTTPMethod: "POST",
  155. HTTPPath: "/",
  156. }
  157. if input == nil {
  158. input = &EnableAlarmActionsInput{}
  159. }
  160. req = c.newRequest(op, input, output)
  161. output = &EnableAlarmActionsOutput{}
  162. req.Data = output
  163. return
  164. }
  165. // Enables actions for the specified alarms.
  166. func (c *CloudWatch) EnableAlarmActions(input *EnableAlarmActionsInput) (*EnableAlarmActionsOutput, error) {
  167. req, out := c.EnableAlarmActionsRequest(input)
  168. err := req.Send()
  169. return out, err
  170. }
  171. const opGetMetricStatistics = "GetMetricStatistics"
  172. // GetMetricStatisticsRequest generates a request for the GetMetricStatistics operation.
  173. func (c *CloudWatch) GetMetricStatisticsRequest(input *GetMetricStatisticsInput) (req *request.Request, output *GetMetricStatisticsOutput) {
  174. op := &request.Operation{
  175. Name: opGetMetricStatistics,
  176. HTTPMethod: "POST",
  177. HTTPPath: "/",
  178. }
  179. if input == nil {
  180. input = &GetMetricStatisticsInput{}
  181. }
  182. req = c.newRequest(op, input, output)
  183. output = &GetMetricStatisticsOutput{}
  184. req.Data = output
  185. return
  186. }
  187. // Gets statistics for the specified metric.
  188. //
  189. // The maximum number of data points returned from a single GetMetricStatistics
  190. // request is 1,440, wereas the maximum number of data points that can be queried
  191. // is 50,850. If you make a request that generates more than 1,440 data points,
  192. // Amazon CloudWatch returns an error. In such a case, you can alter the request
  193. // by narrowing the specified time range or increasing the specified period.
  194. // Alternatively, you can make multiple requests across adjacent time ranges.
  195. //
  196. // Amazon CloudWatch aggregates data points based on the length of the period
  197. // that you specify. For example, if you request statistics with a one-minute
  198. // granularity, Amazon CloudWatch aggregates data points with time stamps that
  199. // fall within the same one-minute period. In such a case, the data points queried
  200. // can greatly outnumber the data points returned.
  201. //
  202. // The following examples show various statistics allowed by the data point
  203. // query maximum of 50,850 when you call GetMetricStatistics on Amazon EC2 instances
  204. // with detailed (one-minute) monitoring enabled:
  205. //
  206. // Statistics for up to 400 instances for a span of one hour Statistics for
  207. // up to 35 instances over a span of 24 hours Statistics for up to 2 instances
  208. // over a span of 2 weeks For information about the namespace, metric names,
  209. // and dimensions that other Amazon Web Services products use to send metrics
  210. // to Cloudwatch, go to Amazon CloudWatch Metrics, Namespaces, and Dimensions
  211. // Reference (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html)
  212. // in the Amazon CloudWatch Developer Guide.
  213. func (c *CloudWatch) GetMetricStatistics(input *GetMetricStatisticsInput) (*GetMetricStatisticsOutput, error) {
  214. req, out := c.GetMetricStatisticsRequest(input)
  215. err := req.Send()
  216. return out, err
  217. }
  218. const opListMetrics = "ListMetrics"
  219. // ListMetricsRequest generates a request for the ListMetrics operation.
  220. func (c *CloudWatch) ListMetricsRequest(input *ListMetricsInput) (req *request.Request, output *ListMetricsOutput) {
  221. op := &request.Operation{
  222. Name: opListMetrics,
  223. HTTPMethod: "POST",
  224. HTTPPath: "/",
  225. Paginator: &request.Paginator{
  226. InputTokens: []string{"NextToken"},
  227. OutputTokens: []string{"NextToken"},
  228. LimitToken: "",
  229. TruncationToken: "",
  230. },
  231. }
  232. if input == nil {
  233. input = &ListMetricsInput{}
  234. }
  235. req = c.newRequest(op, input, output)
  236. output = &ListMetricsOutput{}
  237. req.Data = output
  238. return
  239. }
  240. // Returns a list of valid metrics stored for the AWS account owner. Returned
  241. // metrics can be used with GetMetricStatistics to obtain statistical data for
  242. // a given metric.
  243. func (c *CloudWatch) ListMetrics(input *ListMetricsInput) (*ListMetricsOutput, error) {
  244. req, out := c.ListMetricsRequest(input)
  245. err := req.Send()
  246. return out, err
  247. }
  248. func (c *CloudWatch) ListMetricsPages(input *ListMetricsInput, fn func(p *ListMetricsOutput, lastPage bool) (shouldContinue bool)) error {
  249. page, _ := c.ListMetricsRequest(input)
  250. return page.EachPage(func(p interface{}, lastPage bool) bool {
  251. return fn(p.(*ListMetricsOutput), lastPage)
  252. })
  253. }
  254. const opPutMetricAlarm = "PutMetricAlarm"
  255. // PutMetricAlarmRequest generates a request for the PutMetricAlarm operation.
  256. func (c *CloudWatch) PutMetricAlarmRequest(input *PutMetricAlarmInput) (req *request.Request, output *PutMetricAlarmOutput) {
  257. op := &request.Operation{
  258. Name: opPutMetricAlarm,
  259. HTTPMethod: "POST",
  260. HTTPPath: "/",
  261. }
  262. if input == nil {
  263. input = &PutMetricAlarmInput{}
  264. }
  265. req = c.newRequest(op, input, output)
  266. output = &PutMetricAlarmOutput{}
  267. req.Data = output
  268. return
  269. }
  270. // Creates or updates an alarm and associates it with the specified Amazon CloudWatch
  271. // metric. Optionally, this operation can associate one or more Amazon Simple
  272. // Notification Service resources with the alarm.
  273. //
  274. // When this operation creates an alarm, the alarm state is immediately set
  275. // to INSUFFICIENT_DATA. The alarm is evaluated and its StateValue is set appropriately.
  276. // Any actions associated with the StateValue is then executed.
  277. func (c *CloudWatch) PutMetricAlarm(input *PutMetricAlarmInput) (*PutMetricAlarmOutput, error) {
  278. req, out := c.PutMetricAlarmRequest(input)
  279. err := req.Send()
  280. return out, err
  281. }
  282. const opPutMetricData = "PutMetricData"
  283. // PutMetricDataRequest generates a request for the PutMetricData operation.
  284. func (c *CloudWatch) PutMetricDataRequest(input *PutMetricDataInput) (req *request.Request, output *PutMetricDataOutput) {
  285. op := &request.Operation{
  286. Name: opPutMetricData,
  287. HTTPMethod: "POST",
  288. HTTPPath: "/",
  289. }
  290. if input == nil {
  291. input = &PutMetricDataInput{}
  292. }
  293. req = c.newRequest(op, input, output)
  294. output = &PutMetricDataOutput{}
  295. req.Data = output
  296. return
  297. }
  298. // Publishes metric data points to Amazon CloudWatch. Amazon Cloudwatch associates
  299. // the data points with the specified metric. If the specified metric does not
  300. // exist, Amazon CloudWatch creates the metric. It can take up to fifteen minutes
  301. // for a new metric to appear in calls to the ListMetrics action.
  302. //
  303. // The size of a PutMetricData request is limited to 8 KB for HTTP GET requests
  304. // and 40 KB for HTTP POST requests.
  305. //
  306. // Although the Value parameter accepts numbers of type Double, Amazon CloudWatch
  307. // truncates values with very large exponents. Values with base-10 exponents
  308. // greater than 126 (1 x 10^126) are truncated. Likewise, values with base-10
  309. // exponents less than -130 (1 x 10^-130) are also truncated. Data that is
  310. // timestamped 24 hours or more in the past may take in excess of 48 hours to
  311. // become available from submission time using GetMetricStatistics.
  312. func (c *CloudWatch) PutMetricData(input *PutMetricDataInput) (*PutMetricDataOutput, error) {
  313. req, out := c.PutMetricDataRequest(input)
  314. err := req.Send()
  315. return out, err
  316. }
  317. const opSetAlarmState = "SetAlarmState"
  318. // SetAlarmStateRequest generates a request for the SetAlarmState operation.
  319. func (c *CloudWatch) SetAlarmStateRequest(input *SetAlarmStateInput) (req *request.Request, output *SetAlarmStateOutput) {
  320. op := &request.Operation{
  321. Name: opSetAlarmState,
  322. HTTPMethod: "POST",
  323. HTTPPath: "/",
  324. }
  325. if input == nil {
  326. input = &SetAlarmStateInput{}
  327. }
  328. req = c.newRequest(op, input, output)
  329. output = &SetAlarmStateOutput{}
  330. req.Data = output
  331. return
  332. }
  333. // Temporarily sets the state of an alarm. When the updated StateValue differs
  334. // from the previous value, the action configured for the appropriate state
  335. // is invoked. This is not a permanent change. The next periodic alarm check
  336. // (in about a minute) will set the alarm to its actual state.
  337. func (c *CloudWatch) SetAlarmState(input *SetAlarmStateInput) (*SetAlarmStateOutput, error) {
  338. req, out := c.SetAlarmStateRequest(input)
  339. err := req.Send()
  340. return out, err
  341. }
  342. // The AlarmHistoryItem data type contains descriptive information about the
  343. // history of a specific alarm. If you call DescribeAlarmHistory, Amazon CloudWatch
  344. // returns this data type as part of the DescribeAlarmHistoryResult data type.
  345. type AlarmHistoryItem struct {
  346. // The descriptive name for the alarm.
  347. AlarmName *string `type:"string"`
  348. // Machine-readable data about the alarm in JSON format.
  349. HistoryData *string `type:"string"`
  350. // The type of alarm history item.
  351. HistoryItemType *string `type:"string" enum:"HistoryItemType"`
  352. // A human-readable summary of the alarm history.
  353. HistorySummary *string `type:"string"`
  354. // The time stamp for the alarm history item. Amazon CloudWatch uses Coordinated
  355. // Universal Time (UTC) when returning time stamps, which do not accommodate
  356. // seasonal adjustments such as daylight savings time. For more information,
  357. // see Time stamps (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#about_timestamp)
  358. // in the Amazon CloudWatch Developer Guide.
  359. Timestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  360. metadataAlarmHistoryItem `json:"-" xml:"-"`
  361. }
  362. type metadataAlarmHistoryItem struct {
  363. SDKShapeTraits bool `type:"structure"`
  364. }
  365. // String returns the string representation
  366. func (s AlarmHistoryItem) String() string {
  367. return awsutil.Prettify(s)
  368. }
  369. // GoString returns the string representation
  370. func (s AlarmHistoryItem) GoString() string {
  371. return s.String()
  372. }
  373. // The Datapoint data type encapsulates the statistical data that Amazon CloudWatch
  374. // computes from metric data.
  375. type Datapoint struct {
  376. // The average of metric values that correspond to the datapoint.
  377. Average *float64 `type:"double"`
  378. // The maximum of the metric value used for the datapoint.
  379. Maximum *float64 `type:"double"`
  380. // The minimum metric value used for the datapoint.
  381. Minimum *float64 `type:"double"`
  382. // The number of metric values that contributed to the aggregate value of this
  383. // datapoint.
  384. SampleCount *float64 `type:"double"`
  385. // The sum of metric values used for the datapoint.
  386. Sum *float64 `type:"double"`
  387. // The time stamp used for the datapoint. Amazon CloudWatch uses Coordinated
  388. // Universal Time (UTC) when returning time stamps, which do not accommodate
  389. // seasonal adjustments such as daylight savings time. For more information,
  390. // see Time stamps (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#about_timestamp)
  391. // in the Amazon CloudWatch Developer Guide.
  392. Timestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  393. // The standard unit used for the datapoint.
  394. Unit *string `type:"string" enum:"StandardUnit"`
  395. metadataDatapoint `json:"-" xml:"-"`
  396. }
  397. type metadataDatapoint struct {
  398. SDKShapeTraits bool `type:"structure"`
  399. }
  400. // String returns the string representation
  401. func (s Datapoint) String() string {
  402. return awsutil.Prettify(s)
  403. }
  404. // GoString returns the string representation
  405. func (s Datapoint) GoString() string {
  406. return s.String()
  407. }
  408. type DeleteAlarmsInput struct {
  409. // A list of alarms to be deleted.
  410. AlarmNames []*string `type:"list" required:"true"`
  411. metadataDeleteAlarmsInput `json:"-" xml:"-"`
  412. }
  413. type metadataDeleteAlarmsInput struct {
  414. SDKShapeTraits bool `type:"structure"`
  415. }
  416. // String returns the string representation
  417. func (s DeleteAlarmsInput) String() string {
  418. return awsutil.Prettify(s)
  419. }
  420. // GoString returns the string representation
  421. func (s DeleteAlarmsInput) GoString() string {
  422. return s.String()
  423. }
  424. type DeleteAlarmsOutput struct {
  425. metadataDeleteAlarmsOutput `json:"-" xml:"-"`
  426. }
  427. type metadataDeleteAlarmsOutput struct {
  428. SDKShapeTraits bool `type:"structure"`
  429. }
  430. // String returns the string representation
  431. func (s DeleteAlarmsOutput) String() string {
  432. return awsutil.Prettify(s)
  433. }
  434. // GoString returns the string representation
  435. func (s DeleteAlarmsOutput) GoString() string {
  436. return s.String()
  437. }
  438. type DescribeAlarmHistoryInput struct {
  439. // The name of the alarm.
  440. AlarmName *string `type:"string"`
  441. // The ending date to retrieve alarm history.
  442. EndDate *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  443. // The type of alarm histories to retrieve.
  444. HistoryItemType *string `type:"string" enum:"HistoryItemType"`
  445. // The maximum number of alarm history records to retrieve.
  446. MaxRecords *int64 `type:"integer"`
  447. // The token returned by a previous call to indicate that there is more data
  448. // available.
  449. NextToken *string `type:"string"`
  450. // The starting date to retrieve alarm history.
  451. StartDate *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  452. metadataDescribeAlarmHistoryInput `json:"-" xml:"-"`
  453. }
  454. type metadataDescribeAlarmHistoryInput struct {
  455. SDKShapeTraits bool `type:"structure"`
  456. }
  457. // String returns the string representation
  458. func (s DescribeAlarmHistoryInput) String() string {
  459. return awsutil.Prettify(s)
  460. }
  461. // GoString returns the string representation
  462. func (s DescribeAlarmHistoryInput) GoString() string {
  463. return s.String()
  464. }
  465. // The output for the DescribeAlarmHistory action.
  466. type DescribeAlarmHistoryOutput struct {
  467. // A list of alarm histories in JSON format.
  468. AlarmHistoryItems []*AlarmHistoryItem `type:"list"`
  469. // A string that marks the start of the next batch of returned results.
  470. NextToken *string `type:"string"`
  471. metadataDescribeAlarmHistoryOutput `json:"-" xml:"-"`
  472. }
  473. type metadataDescribeAlarmHistoryOutput struct {
  474. SDKShapeTraits bool `type:"structure"`
  475. }
  476. // String returns the string representation
  477. func (s DescribeAlarmHistoryOutput) String() string {
  478. return awsutil.Prettify(s)
  479. }
  480. // GoString returns the string representation
  481. func (s DescribeAlarmHistoryOutput) GoString() string {
  482. return s.String()
  483. }
  484. type DescribeAlarmsForMetricInput struct {
  485. // The list of dimensions associated with the metric.
  486. Dimensions []*Dimension `type:"list"`
  487. // The name of the metric.
  488. MetricName *string `type:"string" required:"true"`
  489. // The namespace of the metric.
  490. Namespace *string `type:"string" required:"true"`
  491. // The period in seconds over which the statistic is applied.
  492. Period *int64 `type:"integer"`
  493. // The statistic for the metric.
  494. Statistic *string `type:"string" enum:"Statistic"`
  495. // The unit for the metric.
  496. Unit *string `type:"string" enum:"StandardUnit"`
  497. metadataDescribeAlarmsForMetricInput `json:"-" xml:"-"`
  498. }
  499. type metadataDescribeAlarmsForMetricInput struct {
  500. SDKShapeTraits bool `type:"structure"`
  501. }
  502. // String returns the string representation
  503. func (s DescribeAlarmsForMetricInput) String() string {
  504. return awsutil.Prettify(s)
  505. }
  506. // GoString returns the string representation
  507. func (s DescribeAlarmsForMetricInput) GoString() string {
  508. return s.String()
  509. }
  510. // The output for the DescribeAlarmsForMetric action.
  511. type DescribeAlarmsForMetricOutput struct {
  512. // A list of information for each alarm with the specified metric.
  513. MetricAlarms []*MetricAlarm `type:"list"`
  514. metadataDescribeAlarmsForMetricOutput `json:"-" xml:"-"`
  515. }
  516. type metadataDescribeAlarmsForMetricOutput struct {
  517. SDKShapeTraits bool `type:"structure"`
  518. }
  519. // String returns the string representation
  520. func (s DescribeAlarmsForMetricOutput) String() string {
  521. return awsutil.Prettify(s)
  522. }
  523. // GoString returns the string representation
  524. func (s DescribeAlarmsForMetricOutput) GoString() string {
  525. return s.String()
  526. }
  527. type DescribeAlarmsInput struct {
  528. // The action name prefix.
  529. ActionPrefix *string `type:"string"`
  530. // The alarm name prefix. AlarmNames cannot be specified if this parameter is
  531. // specified.
  532. AlarmNamePrefix *string `type:"string"`
  533. // A list of alarm names to retrieve information for.
  534. AlarmNames []*string `type:"list"`
  535. // The maximum number of alarm descriptions to retrieve.
  536. MaxRecords *int64 `type:"integer"`
  537. // The token returned by a previous call to indicate that there is more data
  538. // available.
  539. NextToken *string `type:"string"`
  540. // The state value to be used in matching alarms.
  541. StateValue *string `type:"string" enum:"StateValue"`
  542. metadataDescribeAlarmsInput `json:"-" xml:"-"`
  543. }
  544. type metadataDescribeAlarmsInput struct {
  545. SDKShapeTraits bool `type:"structure"`
  546. }
  547. // String returns the string representation
  548. func (s DescribeAlarmsInput) String() string {
  549. return awsutil.Prettify(s)
  550. }
  551. // GoString returns the string representation
  552. func (s DescribeAlarmsInput) GoString() string {
  553. return s.String()
  554. }
  555. // The output for the DescribeAlarms action.
  556. type DescribeAlarmsOutput struct {
  557. // A list of information for the specified alarms.
  558. MetricAlarms []*MetricAlarm `type:"list"`
  559. // A string that marks the start of the next batch of returned results.
  560. NextToken *string `type:"string"`
  561. metadataDescribeAlarmsOutput `json:"-" xml:"-"`
  562. }
  563. type metadataDescribeAlarmsOutput struct {
  564. SDKShapeTraits bool `type:"structure"`
  565. }
  566. // String returns the string representation
  567. func (s DescribeAlarmsOutput) String() string {
  568. return awsutil.Prettify(s)
  569. }
  570. // GoString returns the string representation
  571. func (s DescribeAlarmsOutput) GoString() string {
  572. return s.String()
  573. }
  574. // The Dimension data type further expands on the identity of a metric using
  575. // a Name, Value pair.
  576. //
  577. // For examples that use one or more dimensions, see PutMetricData.
  578. type Dimension struct {
  579. // The name of the dimension.
  580. Name *string `type:"string" required:"true"`
  581. // The value representing the dimension measurement
  582. Value *string `type:"string" required:"true"`
  583. metadataDimension `json:"-" xml:"-"`
  584. }
  585. type metadataDimension struct {
  586. SDKShapeTraits bool `type:"structure"`
  587. }
  588. // String returns the string representation
  589. func (s Dimension) String() string {
  590. return awsutil.Prettify(s)
  591. }
  592. // GoString returns the string representation
  593. func (s Dimension) GoString() string {
  594. return s.String()
  595. }
  596. // The DimensionFilter data type is used to filter ListMetrics results.
  597. type DimensionFilter struct {
  598. // The dimension name to be matched.
  599. Name *string `type:"string" required:"true"`
  600. // The value of the dimension to be matched.
  601. Value *string `type:"string"`
  602. metadataDimensionFilter `json:"-" xml:"-"`
  603. }
  604. type metadataDimensionFilter struct {
  605. SDKShapeTraits bool `type:"structure"`
  606. }
  607. // String returns the string representation
  608. func (s DimensionFilter) String() string {
  609. return awsutil.Prettify(s)
  610. }
  611. // GoString returns the string representation
  612. func (s DimensionFilter) GoString() string {
  613. return s.String()
  614. }
  615. type DisableAlarmActionsInput struct {
  616. // The names of the alarms to disable actions for.
  617. AlarmNames []*string `type:"list" required:"true"`
  618. metadataDisableAlarmActionsInput `json:"-" xml:"-"`
  619. }
  620. type metadataDisableAlarmActionsInput struct {
  621. SDKShapeTraits bool `type:"structure"`
  622. }
  623. // String returns the string representation
  624. func (s DisableAlarmActionsInput) String() string {
  625. return awsutil.Prettify(s)
  626. }
  627. // GoString returns the string representation
  628. func (s DisableAlarmActionsInput) GoString() string {
  629. return s.String()
  630. }
  631. type DisableAlarmActionsOutput struct {
  632. metadataDisableAlarmActionsOutput `json:"-" xml:"-"`
  633. }
  634. type metadataDisableAlarmActionsOutput struct {
  635. SDKShapeTraits bool `type:"structure"`
  636. }
  637. // String returns the string representation
  638. func (s DisableAlarmActionsOutput) String() string {
  639. return awsutil.Prettify(s)
  640. }
  641. // GoString returns the string representation
  642. func (s DisableAlarmActionsOutput) GoString() string {
  643. return s.String()
  644. }
  645. type EnableAlarmActionsInput struct {
  646. // The names of the alarms to enable actions for.
  647. AlarmNames []*string `type:"list" required:"true"`
  648. metadataEnableAlarmActionsInput `json:"-" xml:"-"`
  649. }
  650. type metadataEnableAlarmActionsInput struct {
  651. SDKShapeTraits bool `type:"structure"`
  652. }
  653. // String returns the string representation
  654. func (s EnableAlarmActionsInput) String() string {
  655. return awsutil.Prettify(s)
  656. }
  657. // GoString returns the string representation
  658. func (s EnableAlarmActionsInput) GoString() string {
  659. return s.String()
  660. }
  661. type EnableAlarmActionsOutput struct {
  662. metadataEnableAlarmActionsOutput `json:"-" xml:"-"`
  663. }
  664. type metadataEnableAlarmActionsOutput struct {
  665. SDKShapeTraits bool `type:"structure"`
  666. }
  667. // String returns the string representation
  668. func (s EnableAlarmActionsOutput) String() string {
  669. return awsutil.Prettify(s)
  670. }
  671. // GoString returns the string representation
  672. func (s EnableAlarmActionsOutput) GoString() string {
  673. return s.String()
  674. }
  675. type GetMetricStatisticsInput struct {
  676. // A list of dimensions describing qualities of the metric.
  677. Dimensions []*Dimension `type:"list"`
  678. // The time stamp to use for determining the last datapoint to return. The value
  679. // specified is exclusive; results will include datapoints up to the time stamp
  680. // specified.
  681. EndTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"`
  682. // The name of the metric, with or without spaces.
  683. MetricName *string `type:"string" required:"true"`
  684. // The namespace of the metric, with or without spaces.
  685. Namespace *string `type:"string" required:"true"`
  686. // The granularity, in seconds, of the returned datapoints. Period must be at
  687. // least 60 seconds and must be a multiple of 60. The default value is 60.
  688. Period *int64 `type:"integer" required:"true"`
  689. // The time stamp to use for determining the first datapoint to return. The
  690. // value specified is inclusive; results include datapoints with the time stamp
  691. // specified.
  692. StartTime *time.Time `type:"timestamp" timestampFormat:"iso8601" required:"true"`
  693. // The metric statistics to return. For information about specific statistics
  694. // returned by GetMetricStatistics, go to Statistics (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/index.html?CHAP_TerminologyandKeyConcepts.html#Statistic)
  695. // in the Amazon CloudWatch Developer Guide.
  696. //
  697. // Valid Values: Average | Sum | SampleCount | Maximum | Minimum
  698. Statistics []*string `type:"list" required:"true"`
  699. // The unit for the metric.
  700. Unit *string `type:"string" enum:"StandardUnit"`
  701. metadataGetMetricStatisticsInput `json:"-" xml:"-"`
  702. }
  703. type metadataGetMetricStatisticsInput struct {
  704. SDKShapeTraits bool `type:"structure"`
  705. }
  706. // String returns the string representation
  707. func (s GetMetricStatisticsInput) String() string {
  708. return awsutil.Prettify(s)
  709. }
  710. // GoString returns the string representation
  711. func (s GetMetricStatisticsInput) GoString() string {
  712. return s.String()
  713. }
  714. // The output for the GetMetricStatistics action.
  715. type GetMetricStatisticsOutput struct {
  716. // The datapoints for the specified metric.
  717. Datapoints []*Datapoint `type:"list"`
  718. // A label describing the specified metric.
  719. Label *string `type:"string"`
  720. metadataGetMetricStatisticsOutput `json:"-" xml:"-"`
  721. }
  722. type metadataGetMetricStatisticsOutput struct {
  723. SDKShapeTraits bool `type:"structure"`
  724. }
  725. // String returns the string representation
  726. func (s GetMetricStatisticsOutput) String() string {
  727. return awsutil.Prettify(s)
  728. }
  729. // GoString returns the string representation
  730. func (s GetMetricStatisticsOutput) GoString() string {
  731. return s.String()
  732. }
  733. type ListMetricsInput struct {
  734. // A list of dimensions to filter against.
  735. Dimensions []*DimensionFilter `type:"list"`
  736. // The name of the metric to filter against.
  737. MetricName *string `type:"string"`
  738. // The namespace to filter against.
  739. Namespace *string `type:"string"`
  740. // The token returned by a previous call to indicate that there is more data
  741. // available.
  742. NextToken *string `type:"string"`
  743. metadataListMetricsInput `json:"-" xml:"-"`
  744. }
  745. type metadataListMetricsInput struct {
  746. SDKShapeTraits bool `type:"structure"`
  747. }
  748. // String returns the string representation
  749. func (s ListMetricsInput) String() string {
  750. return awsutil.Prettify(s)
  751. }
  752. // GoString returns the string representation
  753. func (s ListMetricsInput) GoString() string {
  754. return s.String()
  755. }
  756. // The output for the ListMetrics action.
  757. type ListMetricsOutput struct {
  758. // A list of metrics used to generate statistics for an AWS account.
  759. Metrics []*Metric `type:"list"`
  760. // A string that marks the start of the next batch of returned results.
  761. NextToken *string `type:"string"`
  762. metadataListMetricsOutput `json:"-" xml:"-"`
  763. }
  764. type metadataListMetricsOutput struct {
  765. SDKShapeTraits bool `type:"structure"`
  766. }
  767. // String returns the string representation
  768. func (s ListMetricsOutput) String() string {
  769. return awsutil.Prettify(s)
  770. }
  771. // GoString returns the string representation
  772. func (s ListMetricsOutput) GoString() string {
  773. return s.String()
  774. }
  775. // The Metric data type contains information about a specific metric. If you
  776. // call ListMetrics, Amazon CloudWatch returns information contained by this
  777. // data type.
  778. //
  779. // The example in the Examples section publishes two metrics named buffers
  780. // and latency. Both metrics are in the examples namespace. Both metrics have
  781. // two dimensions, InstanceID and InstanceType.
  782. type Metric struct {
  783. // A list of dimensions associated with the metric.
  784. Dimensions []*Dimension `type:"list"`
  785. // The name of the metric.
  786. MetricName *string `type:"string"`
  787. // The namespace of the metric.
  788. Namespace *string `type:"string"`
  789. metadataMetric `json:"-" xml:"-"`
  790. }
  791. type metadataMetric struct {
  792. SDKShapeTraits bool `type:"structure"`
  793. }
  794. // String returns the string representation
  795. func (s Metric) String() string {
  796. return awsutil.Prettify(s)
  797. }
  798. // GoString returns the string representation
  799. func (s Metric) GoString() string {
  800. return s.String()
  801. }
  802. // The MetricAlarm data type represents an alarm. You can use PutMetricAlarm
  803. // to create or update an alarm.
  804. type MetricAlarm struct {
  805. // Indicates whether actions should be executed during any changes to the alarm's
  806. // state.
  807. ActionsEnabled *bool `type:"boolean"`
  808. // The list of actions to execute when this alarm transitions into an ALARM
  809. // state from any other state. Each action is specified as an Amazon Resource
  810. // Number (ARN). Currently the only actions supported are publishing to an Amazon
  811. // SNS topic and triggering an Auto Scaling policy.
  812. AlarmActions []*string `type:"list"`
  813. // The Amazon Resource Name (ARN) of the alarm.
  814. AlarmArn *string `type:"string"`
  815. // The time stamp of the last update to the alarm configuration. Amazon CloudWatch
  816. // uses Coordinated Universal Time (UTC) when returning time stamps, which do
  817. // not accommodate seasonal adjustments such as daylight savings time. For more
  818. // information, see Time stamps (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#about_timestamp)
  819. // in the Amazon CloudWatch Developer Guide.
  820. AlarmConfigurationUpdatedTimestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  821. // The description for the alarm.
  822. AlarmDescription *string `type:"string"`
  823. // The name of the alarm.
  824. AlarmName *string `type:"string"`
  825. // The arithmetic operation to use when comparing the specified Statistic and
  826. // Threshold. The specified Statistic value is used as the first operand.
  827. ComparisonOperator *string `type:"string" enum:"ComparisonOperator"`
  828. // The list of dimensions associated with the alarm's associated metric.
  829. Dimensions []*Dimension `type:"list"`
  830. // The number of periods over which data is compared to the specified threshold.
  831. EvaluationPeriods *int64 `type:"integer"`
  832. // The list of actions to execute when this alarm transitions into an INSUFFICIENT_DATA
  833. // state from any other state. Each action is specified as an Amazon Resource
  834. // Number (ARN). Currently the only actions supported are publishing to an Amazon
  835. // SNS topic or triggering an Auto Scaling policy.
  836. //
  837. // The current WSDL lists this attribute as UnknownActions.
  838. InsufficientDataActions []*string `type:"list"`
  839. // The name of the alarm's metric.
  840. MetricName *string `type:"string"`
  841. // The namespace of alarm's associated metric.
  842. Namespace *string `type:"string"`
  843. // The list of actions to execute when this alarm transitions into an OK state
  844. // from any other state. Each action is specified as an Amazon Resource Number
  845. // (ARN). Currently the only actions supported are publishing to an Amazon SNS
  846. // topic and triggering an Auto Scaling policy.
  847. OKActions []*string `type:"list"`
  848. // The period in seconds over which the statistic is applied.
  849. Period *int64 `type:"integer"`
  850. // A human-readable explanation for the alarm's state.
  851. StateReason *string `type:"string"`
  852. // An explanation for the alarm's state in machine-readable JSON format
  853. StateReasonData *string `type:"string"`
  854. // The time stamp of the last update to the alarm's state. Amazon CloudWatch
  855. // uses Coordinated Universal Time (UTC) when returning time stamps, which do
  856. // not accommodate seasonal adjustments such as daylight savings time. For more
  857. // information, see Time stamps (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#about_timestamp)
  858. // in the Amazon CloudWatch Developer Guide.
  859. StateUpdatedTimestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  860. // The state value for the alarm.
  861. StateValue *string `type:"string" enum:"StateValue"`
  862. // The statistic to apply to the alarm's associated metric.
  863. Statistic *string `type:"string" enum:"Statistic"`
  864. // The value against which the specified statistic is compared.
  865. Threshold *float64 `type:"double"`
  866. // The unit of the alarm's associated metric.
  867. Unit *string `type:"string" enum:"StandardUnit"`
  868. metadataMetricAlarm `json:"-" xml:"-"`
  869. }
  870. type metadataMetricAlarm struct {
  871. SDKShapeTraits bool `type:"structure"`
  872. }
  873. // String returns the string representation
  874. func (s MetricAlarm) String() string {
  875. return awsutil.Prettify(s)
  876. }
  877. // GoString returns the string representation
  878. func (s MetricAlarm) GoString() string {
  879. return s.String()
  880. }
  881. // The MetricDatum data type encapsulates the information sent with PutMetricData
  882. // to either create a new metric or add new values to be aggregated into an
  883. // existing metric.
  884. type MetricDatum struct {
  885. // A list of dimensions associated with the metric. Note, when using the Dimensions
  886. // value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).
  887. Dimensions []*Dimension `type:"list"`
  888. // The name of the metric.
  889. MetricName *string `type:"string" required:"true"`
  890. // A set of statistical values describing the metric.
  891. StatisticValues *StatisticSet `type:"structure"`
  892. // The time stamp used for the metric. If not specified, the default value is
  893. // set to the time the metric data was received. Amazon CloudWatch uses Coordinated
  894. // Universal Time (UTC) when returning time stamps, which do not accommodate
  895. // seasonal adjustments such as daylight savings time. For more information,
  896. // see Time stamps (http://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/cloudwatch_concepts.html#about_timestamp)
  897. // in the Amazon CloudWatch Developer Guide.
  898. Timestamp *time.Time `type:"timestamp" timestampFormat:"iso8601"`
  899. // The unit of the metric.
  900. Unit *string `type:"string" enum:"StandardUnit"`
  901. // The value for the metric.
  902. //
  903. // Although the Value parameter accepts numbers of type Double, Amazon CloudWatch
  904. // truncates values with very large exponents. Values with base-10 exponents
  905. // greater than 126 (1 x 10^126) are truncated. Likewise, values with base-10
  906. // exponents less than -130 (1 x 10^-130) are also truncated.
  907. Value *float64 `type:"double"`
  908. metadataMetricDatum `json:"-" xml:"-"`
  909. }
  910. type metadataMetricDatum struct {
  911. SDKShapeTraits bool `type:"structure"`
  912. }
  913. // String returns the string representation
  914. func (s MetricDatum) String() string {
  915. return awsutil.Prettify(s)
  916. }
  917. // GoString returns the string representation
  918. func (s MetricDatum) GoString() string {
  919. return s.String()
  920. }
  921. type PutMetricAlarmInput struct {
  922. // Indicates whether or not actions should be executed during any changes to
  923. // the alarm's state.
  924. ActionsEnabled *bool `type:"boolean"`
  925. // The list of actions to execute when this alarm transitions into an ALARM
  926. // state from any other state. Each action is specified as an Amazon Resource
  927. // Number (ARN). Currently the only action supported is publishing to an Amazon
  928. // SNS topic or an Amazon Auto Scaling policy.
  929. AlarmActions []*string `type:"list"`
  930. // The description for the alarm.
  931. AlarmDescription *string `type:"string"`
  932. // The descriptive name for the alarm. This name must be unique within the user's
  933. // AWS account
  934. AlarmName *string `type:"string" required:"true"`
  935. // The arithmetic operation to use when comparing the specified Statistic and
  936. // Threshold. The specified Statistic value is used as the first operand.
  937. ComparisonOperator *string `type:"string" required:"true" enum:"ComparisonOperator"`
  938. // The dimensions for the alarm's associated metric.
  939. Dimensions []*Dimension `type:"list"`
  940. // The number of periods over which data is compared to the specified threshold.
  941. EvaluationPeriods *int64 `type:"integer" required:"true"`
  942. // The list of actions to execute when this alarm transitions into an INSUFFICIENT_DATA
  943. // state from any other state. Each action is specified as an Amazon Resource
  944. // Number (ARN). Currently the only action supported is publishing to an Amazon
  945. // SNS topic or an Amazon Auto Scaling policy.
  946. InsufficientDataActions []*string `type:"list"`
  947. // The name for the alarm's associated metric.
  948. MetricName *string `type:"string" required:"true"`
  949. // The namespace for the alarm's associated metric.
  950. Namespace *string `type:"string" required:"true"`
  951. // The list of actions to execute when this alarm transitions into an OK state
  952. // from any other state. Each action is specified as an Amazon Resource Number
  953. // (ARN). Currently the only action supported is publishing to an Amazon SNS
  954. // topic or an Amazon Auto Scaling policy.
  955. OKActions []*string `type:"list"`
  956. // The period in seconds over which the specified statistic is applied.
  957. Period *int64 `type:"integer" required:"true"`
  958. // The statistic to apply to the alarm's associated metric.
  959. Statistic *string `type:"string" required:"true" enum:"Statistic"`
  960. // The value against which the specified statistic is compared.
  961. Threshold *float64 `type:"double" required:"true"`
  962. // The unit for the alarm's associated metric.
  963. Unit *string `type:"string" enum:"StandardUnit"`
  964. metadataPutMetricAlarmInput `json:"-" xml:"-"`
  965. }
  966. type metadataPutMetricAlarmInput struct {
  967. SDKShapeTraits bool `type:"structure"`
  968. }
  969. // String returns the string representation
  970. func (s PutMetricAlarmInput) String() string {
  971. return awsutil.Prettify(s)
  972. }
  973. // GoString returns the string representation
  974. func (s PutMetricAlarmInput) GoString() string {
  975. return s.String()
  976. }
  977. type PutMetricAlarmOutput struct {
  978. metadataPutMetricAlarmOutput `json:"-" xml:"-"`
  979. }
  980. type metadataPutMetricAlarmOutput struct {
  981. SDKShapeTraits bool `type:"structure"`
  982. }
  983. // String returns the string representation
  984. func (s PutMetricAlarmOutput) String() string {
  985. return awsutil.Prettify(s)
  986. }
  987. // GoString returns the string representation
  988. func (s PutMetricAlarmOutput) GoString() string {
  989. return s.String()
  990. }
  991. type PutMetricDataInput struct {
  992. // A list of data describing the metric.
  993. MetricData []*MetricDatum `type:"list" required:"true"`
  994. // The namespace for the metric data.
  995. Namespace *string `type:"string" required:"true"`
  996. metadataPutMetricDataInput `json:"-" xml:"-"`
  997. }
  998. type metadataPutMetricDataInput struct {
  999. SDKShapeTraits bool `type:"structure"`
  1000. }
  1001. // String returns the string representation
  1002. func (s PutMetricDataInput) String() string {
  1003. return awsutil.Prettify(s)
  1004. }
  1005. // GoString returns the string representation
  1006. func (s PutMetricDataInput) GoString() string {
  1007. return s.String()
  1008. }
  1009. type PutMetricDataOutput struct {
  1010. metadataPutMetricDataOutput `json:"-" xml:"-"`
  1011. }
  1012. type metadataPutMetricDataOutput struct {
  1013. SDKShapeTraits bool `type:"structure"`
  1014. }
  1015. // String returns the string representation
  1016. func (s PutMetricDataOutput) String() string {
  1017. return awsutil.Prettify(s)
  1018. }
  1019. // GoString returns the string representation
  1020. func (s PutMetricDataOutput) GoString() string {
  1021. return s.String()
  1022. }
  1023. type SetAlarmStateInput struct {
  1024. // The descriptive name for the alarm. This name must be unique within the user's
  1025. // AWS account. The maximum length is 255 characters.
  1026. AlarmName *string `type:"string" required:"true"`
  1027. // The reason that this alarm is set to this specific state (in human-readable
  1028. // text format)
  1029. StateReason *string `type:"string" required:"true"`
  1030. // The reason that this alarm is set to this specific state (in machine-readable
  1031. // JSON format)
  1032. StateReasonData *string `type:"string"`
  1033. // The value of the state.
  1034. StateValue *string `type:"string" required:"true" enum:"StateValue"`
  1035. metadataSetAlarmStateInput `json:"-" xml:"-"`
  1036. }
  1037. type metadataSetAlarmStateInput struct {
  1038. SDKShapeTraits bool `type:"structure"`
  1039. }
  1040. // String returns the string representation
  1041. func (s SetAlarmStateInput) String() string {
  1042. return awsutil.Prettify(s)
  1043. }
  1044. // GoString returns the string representation
  1045. func (s SetAlarmStateInput) GoString() string {
  1046. return s.String()
  1047. }
  1048. type SetAlarmStateOutput struct {
  1049. metadataSetAlarmStateOutput `json:"-" xml:"-"`
  1050. }
  1051. type metadataSetAlarmStateOutput struct {
  1052. SDKShapeTraits bool `type:"structure"`
  1053. }
  1054. // String returns the string representation
  1055. func (s SetAlarmStateOutput) String() string {
  1056. return awsutil.Prettify(s)
  1057. }
  1058. // GoString returns the string representation
  1059. func (s SetAlarmStateOutput) GoString() string {
  1060. return s.String()
  1061. }
  1062. // The StatisticSet data type describes the StatisticValues component of MetricDatum,
  1063. // and represents a set of statistics that describes a specific metric.
  1064. type StatisticSet struct {
  1065. // The maximum value of the sample set.
  1066. Maximum *float64 `type:"double" required:"true"`
  1067. // The minimum value of the sample set.
  1068. Minimum *float64 `type:"double" required:"true"`
  1069. // The number of samples used for the statistic set.
  1070. SampleCount *float64 `type:"double" required:"true"`
  1071. // The sum of values for the sample set.
  1072. Sum *float64 `type:"double" required:"true"`
  1073. metadataStatisticSet `json:"-" xml:"-"`
  1074. }
  1075. type metadataStatisticSet struct {
  1076. SDKShapeTraits bool `type:"structure"`
  1077. }
  1078. // String returns the string representation
  1079. func (s StatisticSet) String() string {
  1080. return awsutil.Prettify(s)
  1081. }
  1082. // GoString returns the string representation
  1083. func (s StatisticSet) GoString() string {
  1084. return s.String()
  1085. }
  1086. const (
  1087. // @enum ComparisonOperator
  1088. ComparisonOperatorGreaterThanOrEqualToThreshold = "GreaterThanOrEqualToThreshold"
  1089. // @enum ComparisonOperator
  1090. ComparisonOperatorGreaterThanThreshold = "GreaterThanThreshold"
  1091. // @enum ComparisonOperator
  1092. ComparisonOperatorLessThanThreshold = "LessThanThreshold"
  1093. // @enum ComparisonOperator
  1094. ComparisonOperatorLessThanOrEqualToThreshold = "LessThanOrEqualToThreshold"
  1095. )
  1096. const (
  1097. // @enum HistoryItemType
  1098. HistoryItemTypeConfigurationUpdate = "ConfigurationUpdate"
  1099. // @enum HistoryItemType
  1100. HistoryItemTypeStateUpdate = "StateUpdate"
  1101. // @enum HistoryItemType
  1102. HistoryItemTypeAction = "Action"
  1103. )
  1104. const (
  1105. // @enum StandardUnit
  1106. StandardUnitSeconds = "Seconds"
  1107. // @enum StandardUnit
  1108. StandardUnitMicroseconds = "Microseconds"
  1109. // @enum StandardUnit
  1110. StandardUnitMilliseconds = "Milliseconds"
  1111. // @enum StandardUnit
  1112. StandardUnitBytes = "Bytes"
  1113. // @enum StandardUnit
  1114. StandardUnitKilobytes = "Kilobytes"
  1115. // @enum StandardUnit
  1116. StandardUnitMegabytes = "Megabytes"
  1117. // @enum StandardUnit
  1118. StandardUnitGigabytes = "Gigabytes"
  1119. // @enum StandardUnit
  1120. StandardUnitTerabytes = "Terabytes"
  1121. // @enum StandardUnit
  1122. StandardUnitBits = "Bits"
  1123. // @enum StandardUnit
  1124. StandardUnitKilobits = "Kilobits"
  1125. // @enum StandardUnit
  1126. StandardUnitMegabits = "Megabits"
  1127. // @enum StandardUnit
  1128. StandardUnitGigabits = "Gigabits"
  1129. // @enum StandardUnit
  1130. StandardUnitTerabits = "Terabits"
  1131. // @enum StandardUnit
  1132. StandardUnitPercent = "Percent"
  1133. // @enum StandardUnit
  1134. StandardUnitCount = "Count"
  1135. // @enum StandardUnit
  1136. StandardUnitBytesSecond = "Bytes/Second"
  1137. // @enum StandardUnit
  1138. StandardUnitKilobytesSecond = "Kilobytes/Second"
  1139. // @enum StandardUnit
  1140. StandardUnitMegabytesSecond = "Megabytes/Second"
  1141. // @enum StandardUnit
  1142. StandardUnitGigabytesSecond = "Gigabytes/Second"
  1143. // @enum StandardUnit
  1144. StandardUnitTerabytesSecond = "Terabytes/Second"
  1145. // @enum StandardUnit
  1146. StandardUnitBitsSecond = "Bits/Second"
  1147. // @enum StandardUnit
  1148. StandardUnitKilobitsSecond = "Kilobits/Second"
  1149. // @enum StandardUnit
  1150. StandardUnitMegabitsSecond = "Megabits/Second"
  1151. // @enum StandardUnit
  1152. StandardUnitGigabitsSecond = "Gigabits/Second"
  1153. // @enum StandardUnit
  1154. StandardUnitTerabitsSecond = "Terabits/Second"
  1155. // @enum StandardUnit
  1156. StandardUnitCountSecond = "Count/Second"
  1157. // @enum StandardUnit
  1158. StandardUnitNone = "None"
  1159. )
  1160. const (
  1161. // @enum StateValue
  1162. StateValueOk = "OK"
  1163. // @enum StateValue
  1164. StateValueAlarm = "ALARM"
  1165. // @enum StateValue
  1166. StateValueInsufficientData = "INSUFFICIENT_DATA"
  1167. )
  1168. const (
  1169. // @enum Statistic
  1170. StatisticSampleCount = "SampleCount"
  1171. // @enum Statistic
  1172. StatisticAverage = "Average"
  1173. // @enum Statistic
  1174. StatisticSum = "Sum"
  1175. // @enum Statistic
  1176. StatisticMinimum = "Minimum"
  1177. // @enum Statistic
  1178. StatisticMaximum = "Maximum"
  1179. )