@@ -186,6 +186,13 @@ components:
186
186
required: true
187
187
schema:
188
188
type: string
189
+ BudgetID:
190
+ description: Budget id.
191
+ in: path
192
+ name: budget_id
193
+ required: true
194
+ schema:
195
+ type: string
189
196
CaseIDPathParameter:
190
197
description: Case's UUID or key
191
198
example: f98a5a5b-e0ff-45d4-b2f5-afe6e74de504
@@ -4664,6 +4671,166 @@ components:
4664
4671
data:
4665
4672
$ref: '#/components/schemas/BillingDimensionsMappingBody'
4666
4673
type: object
4674
+ Budget:
4675
+ description: A budget.
4676
+ properties:
4677
+ created_at:
4678
+ description: The timestamp when the budget was created.
4679
+ format: int64
4680
+ type: integer
4681
+ created_by:
4682
+ description: The id of the user that created the budget.
4683
+ type: string
4684
+ end_month:
4685
+ description: The month when the budget ends.
4686
+ format: int64
4687
+ type: integer
4688
+ id:
4689
+ description: The id of the budget.
4690
+ type: string
4691
+ metrics_query:
4692
+ description: The cost query used to track against the budget.
4693
+ type: string
4694
+ name:
4695
+ description: The name of the budget.
4696
+ type: string
4697
+ org_id:
4698
+ description: The id of the org the budget belongs to.
4699
+ format: int64
4700
+ type: integer
4701
+ start_month:
4702
+ description: The month when the budget starts.
4703
+ format: int64
4704
+ type: integer
4705
+ total_amount:
4706
+ description: The sum of all budget entries' amounts.
4707
+ format: double
4708
+ type: number
4709
+ updated_at:
4710
+ description: The timestamp when the budget was last updated.
4711
+ format: int64
4712
+ type: integer
4713
+ updated_by:
4714
+ description: The id of the user that created the budget.
4715
+ type: string
4716
+ type: object
4717
+ BudgetArray:
4718
+ description: An array of budgets.
4719
+ example:
4720
+ data:
4721
+ - attributes:
4722
+ created_at: 1741011342772
4723
+ created_by: user1
4724
+ end_month: 202502
4725
+ metrics_query: aws.cost.amortized{service:ec2} by {service}
4726
+ name: my budget
4727
+ org_id: 123
4728
+ start_month: 202501
4729
+ total_amount: 1000
4730
+ updated_at: 1741011342772
4731
+ updated_by: user2
4732
+ id: 00000000-0a0a-0a0a-aaa0-00000000000a
4733
+ type: budget
4734
+ properties:
4735
+ data:
4736
+ description: The `BudgetArray` `data`.
4737
+ items:
4738
+ $ref: '#/components/schemas/Budget'
4739
+ type: array
4740
+ type: object
4741
+ BudgetEntry:
4742
+ description: The entry of a budget.
4743
+ properties:
4744
+ amount:
4745
+ description: The `amount` of the budget entry.
4746
+ example: 500
4747
+ format: double
4748
+ type: number
4749
+ month:
4750
+ description: The `month` of the budget entry.
4751
+ example: 202501
4752
+ format: int64
4753
+ type: integer
4754
+ tag_filters:
4755
+ description: The `BudgetEntry` `tag_filters`.
4756
+ items:
4757
+ $ref: '#/components/schemas/TagFilter'
4758
+ type: array
4759
+ type: object
4760
+ BudgetWithEntries:
4761
+ description: The definition of the `BudgetWithEntries` object.
4762
+ properties:
4763
+ data:
4764
+ $ref: '#/components/schemas/BudgetWithEntriesData'
4765
+ type: object
4766
+ BudgetWithEntriesAttributes:
4767
+ description: The definition of `BudgetWithEntriesAttributes` object.
4768
+ properties:
4769
+ created_at:
4770
+ description: The timestamp when the budget was created.
4771
+ example: 1738258683590
4772
+ format: int64
4773
+ type: integer
4774
+ created_by:
4775
+ description: The id of the user that created the budget.
4776
+ example: 00000000-0a0a-0a0a-aaa0-00000000000a
4777
+ type: string
4778
+ end_month:
4779
+ description: The month when the budget ends.
4780
+ example: 202502
4781
+ format: int64
4782
+ type: integer
4783
+ entries:
4784
+ description: The entries of the budget.
4785
+ items:
4786
+ $ref: '#/components/schemas/BudgetEntry'
4787
+ type: array
4788
+ metrics_query:
4789
+ description: The cost query used to track against the budget.
4790
+ example: aws.cost.amortized{service:ec2} by {service}
4791
+ type: string
4792
+ name:
4793
+ description: The name of the budget.
4794
+ example: my budget
4795
+ type: string
4796
+ org_id:
4797
+ description: The id of the org the budget belongs to.
4798
+ example: 123
4799
+ format: int64
4800
+ type: integer
4801
+ start_month:
4802
+ description: The month when the budget starts.
4803
+ example: 202501
4804
+ format: int64
4805
+ type: integer
4806
+ total_amount:
4807
+ description: The sum of all budget entries' amounts.
4808
+ example: 1000
4809
+ format: double
4810
+ type: number
4811
+ updated_at:
4812
+ description: The timestamp when the budget was last updated.
4813
+ example: 1738258683590
4814
+ format: int64
4815
+ type: integer
4816
+ updated_by:
4817
+ description: The id of the user that created the budget.
4818
+ example: 00000000-0a0a-0a0a-aaa0-00000000000a
4819
+ type: string
4820
+ type: object
4821
+ BudgetWithEntriesData:
4822
+ description: A budget and all its entries.
4823
+ properties:
4824
+ attributes:
4825
+ $ref: '#/components/schemas/BudgetWithEntriesAttributes'
4826
+ id:
4827
+ description: The `BudgetWithEntriesData` `id`.
4828
+ example: 00000000-0a0a-0a0a-aaa0-00000000000a
4829
+ type: string
4830
+ type:
4831
+ description: The type of the budget.
4832
+ type: string
4833
+ type: object
4667
4834
BulkMuteFindingsRequest:
4668
4835
description: The new bulk mute finding request.
4669
4836
properties:
@@ -34059,6 +34226,18 @@ components:
34059
34226
format: double
34060
34227
type: number
34061
34228
type: object
34229
+ TagFilter:
34230
+ description: Tag filter for the budget's entries.
34231
+ properties:
34232
+ tag_key:
34233
+ description: The key of the tag.
34234
+ example: service
34235
+ type: string
34236
+ tag_value:
34237
+ description: The value of the tag.
34238
+ example: ec2
34239
+ type: string
34240
+ type: object
34062
34241
TagsEventAttribute:
34063
34242
description: Array of tags associated with your event.
34064
34243
example:
@@ -40412,6 +40591,105 @@ paths:
40412
40591
operator: OR
40413
40592
permissions:
40414
40593
- cloud_cost_management_write
40594
+ /api/v2/cost/budget:
40595
+ put:
40596
+ description: Create a new budget or update an existing one.
40597
+ operationId: UpsertBudget
40598
+ requestBody:
40599
+ content:
40600
+ application/json:
40601
+ schema:
40602
+ $ref: '#/components/schemas/BudgetWithEntries'
40603
+ required: true
40604
+ responses:
40605
+ '200':
40606
+ content:
40607
+ application/json:
40608
+ schema:
40609
+ $ref: '#/components/schemas/BudgetWithEntries'
40610
+ description: OK
40611
+ '400':
40612
+ $ref: '#/components/responses/BadRequestResponse'
40613
+ '404':
40614
+ $ref: '#/components/responses/NotFoundResponse'
40615
+ '429':
40616
+ $ref: '#/components/responses/TooManyRequestsResponse'
40617
+ security:
40618
+ - apiKeyAuth: []
40619
+ appKeyAuth: []
40620
+ - AuthZ:
40621
+ - cloud_cost_management_write
40622
+ summary: Update if exists, or create a new budget
40623
+ tags:
40624
+ - Cloud Cost Management
40625
+ /api/v2/cost/budget/{budget_id}:
40626
+ delete:
40627
+ description: Delete a budget.
40628
+ operationId: DeleteBudget
40629
+ parameters:
40630
+ - $ref: '#/components/parameters/BudgetID'
40631
+ responses:
40632
+ '204':
40633
+ description: No Content
40634
+ '400':
40635
+ $ref: '#/components/responses/BadRequestResponse'
40636
+ '429':
40637
+ $ref: '#/components/responses/TooManyRequestsResponse'
40638
+ security:
40639
+ - apiKeyAuth: []
40640
+ appKeyAuth: []
40641
+ - AuthZ:
40642
+ - cloud_cost_management_write
40643
+ summary: Delete a budget
40644
+ tags:
40645
+ - Cloud Cost Management
40646
+ get:
40647
+ description: Get a budget.
40648
+ operationId: GetBudget
40649
+ parameters:
40650
+ - $ref: '#/components/parameters/BudgetID'
40651
+ responses:
40652
+ '200':
40653
+ content:
40654
+ application/json:
40655
+ schema:
40656
+ $ref: '#/components/schemas/BudgetWithEntries'
40657
+ description: OK
40658
+ '400':
40659
+ $ref: '#/components/responses/BadRequestResponse'
40660
+ '404':
40661
+ $ref: '#/components/responses/NotFoundResponse'
40662
+ '429':
40663
+ $ref: '#/components/responses/TooManyRequestsResponse'
40664
+ security:
40665
+ - apiKeyAuth: []
40666
+ appKeyAuth: []
40667
+ - AuthZ:
40668
+ - cloud_cost_management_read
40669
+ summary: Get a budget
40670
+ tags:
40671
+ - Cloud Cost Management
40672
+ /api/v2/cost/budgets:
40673
+ get:
40674
+ description: List budgets.
40675
+ operationId: ListBudgets
40676
+ responses:
40677
+ '200':
40678
+ content:
40679
+ application/json:
40680
+ schema:
40681
+ $ref: '#/components/schemas/BudgetArray'
40682
+ description: OK
40683
+ '429':
40684
+ $ref: '#/components/responses/TooManyRequestsResponse'
40685
+ security:
40686
+ - apiKeyAuth: []
40687
+ appKeyAuth: []
40688
+ - AuthZ:
40689
+ - cloud_cost_management_read
40690
+ summary: List budgets
40691
+ tags:
40692
+ - Cloud Cost Management
40415
40693
/api/v2/cost/custom_costs:
40416
40694
get:
40417
40695
description: List the Custom Costs files.
0 commit comments