Integrate your GCP Account with CloudSpend
Google Cloud Platform (GCP) cost management is essential for anyone responsible for running their resources in the GCP. CloudSpend allows you to integrate your GCP account and manage your cloud bills.
You can connect your GCP account with CloudSpend by following the steps below:
- Export billing data to the BigQuery data set from your GCP account.
- Create a service account and obtain the service account JSON key.
- Connect your GCP account with CloudSpend.
- GCP Cloud Billing report uses the Pacific Time Zone and observes daylight saving time shifts. However, CloudSpend uses the UTC time zone. You may notice some cloud cost differences between CloudSpend and the GCP Cloud Billing report due to the time zone difference.
- GCP offers two types of time ranges for cost breakdown: Usage date and Invoice month. Currently, CloudSpend provides usage-based costs within a specified time range for GCP accounts.
CloudSpend-GCP integration architecture
Export billing data
Export the billing data to the BigQuery data set and obtain the Dataset ID to integrate your GCP account with CloudSpend.
Follow the steps below to export the billing data:
- Log in to the GCP console and navigate to the Billing section in the menu.
- Select the Billing Export tab.
- In the BIGQUERY EXPORT tab, click EDIT SETTINGS under the Detailed usage cost section.
- Select the applicable project from the Projects list. The billing data will be exported to BigQuery in the selected project.
- Create a new data set or select an existing data set for exporting billing data to BigQuery from the Data set drop-down.
- Click SAVE.
- Ensure that Detailed usage cost is enabled.
- Click the Data set name hyperlink.
- Copy the Data set ID and paste it in the Dataset ID field found on the CloudSpend Integrate Account page.
Create a service account and obtain the service account JSON key
Follow the steps below to create service accounts:
- From the navigation menu, go to IAM and admin > Service accounts. Ensure that you are in the same project that has configured billing to be exported to BigQuery.
- Click CREATE SERVICE ACCOUNT.
- Provide the Service account details.
- Click CREATE AND CONTINUE.
- Choose Viewer as the role in the Grant this service account access to the project section.
- Click DONE.
To download the service account JSON key, follow the below steps:
- On the Service accounts page, click the vertical ellipsis icon under Actions for the respective service account.
- Select Manage keys.
- Click ADD KEY.
- Select Create new key.
- Select JSON as the Key type.
- Click CREATE. The private key will be downloaded to your system.
Connect your GCP account with CloudSpend
After entering the Dataset ID and obtaining the JSON key, you can connect your GCP account with CloudSpend.
To connect your GCP account with CloudSpend:
- Open the CloudSpend web console and sign in.
- When you open the CloudSpend console for the first time, you'll land on an onboarding carousel highlighting the features of the app. You can read and understand how the app can help you, or you can choose to skip.
- Click Integrate Account.
- Provide a Display Name.
- Set the Public Cloud Provider as GCP.
- Enter the Dataset ID that you created while exporting the billing data.
- Upload the JSON key file from your system to the Service Account JSON Key File field.
- The Start date for bill processing determines the month from which your bills get processed. Select the applicable month.
- Click Save to connect your GCP account with CloudSpend.