From 37ce8005574c32a08f287d54fd4929fa287eda6e Mon Sep 17 00:00:00 2001 From: Kishea Kate Andoy Date: Thu, 26 Mar 2026 11:45:46 +0800 Subject: [PATCH 1/4] Add optional fields for month and columns in GetExportRISPRequest; include emailSent in GetExportRISPResponse --- cost/v1/cost.proto | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cost/v1/cost.proto b/cost/v1/cost.proto index eecab53a..9017b7a9 100644 --- a/cost/v1/cost.proto +++ b/cost/v1/cost.proto @@ -1822,6 +1822,10 @@ message GetExportRISPRequest { string language = 2 [(google.api.field_behavior) = OPTIONAL]; // Required. Include expired bool includeExpired = 3; + // Optional. Target export month in YYYY-MM format. Defaults to current month if empty. + string month = 4 [(google.api.field_behavior) = OPTIONAL]; + // Optional. Columns to include in the CSV output. Empty means all columns. + repeated string columns = 5 [(google.api.field_behavior) = OPTIONAL]; } // Request message for the ExportBillingGroupInvoiceServiceDiscounts rpc. @@ -1829,6 +1833,8 @@ message GetExportRISPResponse { // csv direct download link // expires in 10 minutes string downloadLink = 1; + // True when the export CSV was sent as an email attachment to configured recipients. + bool emailSent = 2; } // Request message for GetUtilization From 875eae34ec50b49f70e15bb1b5c0dbd9b75bf577 Mon Sep 17 00:00:00 2001 From: Kishea Kate Andoy Date: Thu, 26 Mar 2026 19:54:47 +0800 Subject: [PATCH 2/4] Add optional fields to GetExportRISPRequest and ExportCostFiltersFileRequest for enhanced export functionality --- cost/v1/cost.proto | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/cost/v1/cost.proto b/cost/v1/cost.proto index 9017b7a9..4e6284e2 100644 --- a/cost/v1/cost.proto +++ b/cost/v1/cost.proto @@ -1814,6 +1814,10 @@ message GetCostReductionResponse { } message GetExportRISPRequest { + message Columns { + repeated string values = 1; + } + // Required. For AWS, "ri" or "sp". string type = 1; // Usually the language of the user information is used, @@ -1826,6 +1830,13 @@ message GetExportRISPRequest { string month = 4 [(google.api.field_behavior) = OPTIONAL]; // Optional. Columns to include in the CSV output. Empty means all columns. repeated string columns = 5 [(google.api.field_behavior) = OPTIONAL]; + // Optional report names to generate. + // Valid values: ri_summary, sp_summary, ri_usageaccount, sp_usageaccount. + repeated string queries = 6 [(google.api.field_behavior) = OPTIONAL]; + // Optional per-query columns map. When set, values override `columns` for the matching query. + map columnsByQuery = 7; + // Optional. When true, only the invoice-finalization gate is checked and no export email is sent. + bool checkOnly = 8; } // Request message for the ExportBillingGroupInvoiceServiceDiscounts rpc. @@ -2113,6 +2124,8 @@ message ExportCostFiltersFileRequest { // Optional. If set to true, stream will include resource tags. bool includeTags = 7; + // Optional. List of notification channel IDs to send the export result to. + repeated string notificationChannelIds = 8; } // Response message for the ExportCostFiltersFile rpc. From d9b6f2d954caced4294b30d67fa137ad86f7b169 Mon Sep 17 00:00:00 2001 From: Kishea Kate Andoy Date: Thu, 26 Mar 2026 20:51:04 +0800 Subject: [PATCH 3/4] fix: remove duplicate notificationChannelIds field in ExportCostFiltersFileRequest --- cost/v1/cost.proto | 3 --- 1 file changed, 3 deletions(-) diff --git a/cost/v1/cost.proto b/cost/v1/cost.proto index 4e6284e2..abbbe97b 100644 --- a/cost/v1/cost.proto +++ b/cost/v1/cost.proto @@ -2105,9 +2105,6 @@ message ExportCostFiltersFileRequest { // Required. Filter Id. string filterId = 2; - // Required. The channel ids to use for notifications. - repeated string notificationChannelIds = 8; - // Optional. The UTC date to start streaming data from. If not set, the first day of the current month will be used. Format: `yyyymmdd`. The oldest supported date is `20200101`. string startTime = 3; From 9cb12183f54c1a2e56d666e9500edc29c24a83d7 Mon Sep 17 00:00:00 2001 From: Kishea Kate Andoy Date: Fri, 27 Mar 2026 17:07:34 +0800 Subject: [PATCH 4/4] generate openapiv2/apidocs.swagger.json --- openapiv2/apidocs.swagger.json | 58 ++++++++++++++++++++++++++++++---- 1 file changed, 51 insertions(+), 7 deletions(-) diff --git a/openapiv2/apidocs.swagger.json b/openapiv2/apidocs.swagger.json index cae9286c..28146979 100644 --- a/openapiv2/apidocs.swagger.json +++ b/openapiv2/apidocs.swagger.json @@ -23991,13 +23991,6 @@ "CostExportCostFiltersFileBody": { "type": "object", "properties": { - "notificationChannelIds": { - "type": "array", - "items": { - "type": "string" - }, - "description": "Required. The channel ids to use for notifications." - }, "startTime": { "type": "string", "description": "Optional. The UTC date to start streaming data from. If not set, the first day of the current month will be used. Format: `yyyymmdd`. The oldest supported date is `20200101`." @@ -24017,6 +24010,13 @@ "includeTags": { "type": "boolean", "description": "Optional. If set to true, stream will include resource tags." + }, + "notificationChannelIds": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Optional. List of notification channel IDs to send the export result to." } }, "description": "Request message for the ExportCostFiltersFile rpc." @@ -25806,6 +25806,17 @@ } } }, + "GetExportRISPRequestColumns": { + "type": "object", + "properties": { + "values": { + "type": "array", + "items": { + "type": "string" + } + } + } + }, "GetOnboardingStatusResponseOnboardingStatus": { "type": "string", "enum": [ @@ -42548,6 +42559,35 @@ "includeExpired": { "type": "boolean", "title": "Required. Include expired" + }, + "month": { + "type": "string", + "description": "Optional. Target export month in YYYY-MM format. Defaults to current month if empty." + }, + "columns": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Optional. Columns to include in the CSV output. Empty means all columns." + }, + "queries": { + "type": "array", + "items": { + "type": "string" + }, + "description": "Optional report names to generate.\nValid values: ri_summary, sp_summary, ri_usageaccount, sp_usageaccount." + }, + "columnsByQuery": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/GetExportRISPRequestColumns" + }, + "description": "Optional per-query columns map. When set, values override `columns` for the matching query." + }, + "checkOnly": { + "type": "boolean", + "description": "Optional. When true, only the invoice-finalization gate is checked and no export email is sent." } } }, @@ -42557,6 +42597,10 @@ "downloadLink": { "type": "string", "title": "csv direct download link\nexpires in 10 minutes" + }, + "emailSent": { + "type": "boolean", + "description": "True when the export CSV was sent as an email attachment to configured recipients." } }, "description": "Request message for the ExportBillingGroupInvoiceServiceDiscounts rpc."