Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

Why is there a discrepancy between account_budget data from the Ads API and the actual billing dashboard?

47 views
Skip to first unread message

정국영

unread,
Apr 7, 2025, 6:25:10 AMApr 7
to Google Ads API and AdWords API Forum

Hi,
I'm using the Google Ads API to retrieve budget information via the account_budget resource. However, I noticed that the values returned (such as amount_served_micros or total_adjustments_micros) often do not match the figures shown in the Google Ads billing dashboard.

Could you please help me understand why there might be discrepancies between the API data and the actual billing information? Are there any known delays, differences in calculation methods, or additional adjustments that are not reflected in the API response?

Thank you in advance!

Google Ads API Forum Advisor

unread,
Apr 7, 2025, 10:43:42 AMApr 7
to jky...@9dock.co.kr, adwor...@googlegroups.com
Hi,

Upon checking the provided information, I could see that you are getting a discrepancy in budget data retrieved between the Google Ads UI and the Google Ads API. We would like to specify first the following when comparing the value of the Google Ads UI and Google Ads API.
  • The segments and fields of the API and UI should be the same.
  • The date range should also be the same.
  • Comparing the API and UI at the same level as possible.
Also, in order to investigate your issue further, kindly provide us with the complete API logs (request and response with request-id and request header) generated at your end along with the uncropped UI screenshot by highlighting the fields that you are trying to retrieve from the account_budget report via the Google Ads API.

If you are using a client library and haven't enabled the logging yet, I would request you to enable logging for the specific client library that you are using. You can refer to the guides Java.NetPHPPythonRuby or Perl to enable logging at your end. For REST interface requests, you can enable logging via the curl command by using the -i flag.

You can send the details via Reply privately to the author option, or direct private reply to this email.
 

Thanks,
 
Google Logo Google Ads API Team

Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5
[2025-04-07 14:42:46Z GMT] This message is in relation to case "ref:!00D1U01174p.!500Ht01pRXnS:ref" (ADR-00298815)



정국영

unread,
Apr 17, 2025, 2:38:23 AMApr 17
to Google Ads API and AdWords API Forum
Hello,

The code I’m currently using to retrieve budget information is as follows:


async getCustomerAccountBudgets(customerId: string, refreshToken: string, loginCustomerId: string) {
        try {
            const customer = await this.getCustomer(customerId, refreshToken, loginCustomerId)
            console.log('getCustomerAccountBudgets customer', customer)
           
            // return customer

            const results = await customer.report({
                entity: 'account_budget',
                attributes: [
                    "account_budget.id",
                    "account_budget.name",
                    "account_budget.status",
                    "account_budget.proposed_spending_limit_micros",
                    "account_budget.approved_spending_limit_micros",
                    "account_budget.adjusted_spending_limit_micros",
                    "account_budget.total_adjustments_micros",
                    "account_budget.amount_served_micros",
                    "account_budget.purchase_order_number",
                    "account_budget.notes",

                    "account_budget.approved_start_date_time",
                    "account_budget.approved_end_time_type",
                    "account_budget.approved_end_date_time",

                    "account_budget.proposed_start_date_time",
                    "account_budget.proposed_end_time_type",
                    "account_budget.proposed_end_date_time",
                    "account_budget.resource_name"
                    // "account_budget.start_date_time",
                    // "account_budget.start_time_type",
                    // "account_budget.end_date_time",
                    // "account_budget.end_time_type",
                   

                    // "account_budget.approved_start_date_time",
                    // "account_budget.approved_end_date_time",
                    // "account_budget.id",
                    // "account_budget.name",
                    // "account_budget.billing_setup",
                    // "account_budget.status",
                    // "account_budget.amount_served_micros",
                    // "account_budget.proposed_spending_limit_micros"
                ],
                metrics: [],
                segments: [] // Google Ads의 metrics 필드와 segments 필드를 조합하면 광고 성과 데이터를 다양한 각도에서 분석할 수 있습니다. 예를 들어, 일별, 주별, 월별 광고 클릭 수, 노출 수, 전환 수 등을 분석하거나, 특정 장치(모바일, 데스크탑 등)나 위치별로 성과를 분석할 수 있습니다.
               
            })

            console.log('getCustomerAccountBudgets results', results)
            /**
             *
             */
            return {
                statusCode: 200, // statusCode,
                data: results,
                message: '',
                accessToken: '',
                refreshToken: refreshToken,
            }

My understanding is that:

  • adjusted_spending_limit_micros represents the final approved budget after adjustments (e.g., credits, modifications).

  • amount_served_micros represents the actual spend so far.

So, logically, the remaining budget (or balance) should be calculated as:

adjusted_spending_limit_micros - amount_served_micros

However, I’ve noticed that this calculated value does not match the "available funds" shown in the Google Ads UI dashboard. Could you clarify why this discrepancy exists? Is the UI applying any additional logic or adjustments that are not exposed via the API?



2025년 4월 7일 월요일 오후 11시 43분 42초 UTC+9에 Google Ads API Forum Advisor님이 작성:

Google Ads API Forum Advisor

unread,
Apr 17, 2025, 7:28:34 AMApr 17
to jky...@9dock.co.kr, adwor...@googlegroups.com
Hi,

I will check with our team regarding your issue and one of my team members will reach out to you once we have an update on this. Meanwhile, your patience is highly appreciated.
 

Thanks,
 
Google Logo Google Ads API Team

Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5

[2025-04-17 11:27:16Z GMT] This message is in relation to case "ref:!00D1U01174p.!500Ht01pRXnS:ref" (ADR-00298815)



Google Ads API Forum Advisor

unread,
Apr 17, 2025, 3:35:12 PMApr 17
to adwor...@googlegroups.com, jky...@9dock.co.kr
Hi:
 

Thanks for reaching out and providing the details of your calculation and the discrepancy you're observing between the Google Ads API and the UI for available funds.

You are correct in your understanding that subtracting amount_served_micros from adjusted_spending_limit_micros is a common way to estimate the remaining budget using the API.

However, the discrepancy you've noticed between this calculated value and the "Available funds" displayed in the Google Ads UI is a known behavior.

Here's why this difference can occur:

  1. UI Calculation Complexity: As you suspected, the Google Ads UI often incorporates additional factors and performs more complex calculations to determine the "Available funds" figure. This can include:

    • Adjustments that are pending or haven't fully propagated to the specific API fields you're querying.

    • Application of certain types of credits or promotions.

    • Internal calculations related to billing cycles or thresholds that aren't directly exposed via the adjusted_spending_limit_micros and amount_served_micros fields alone.

    • Slight timing differences in data refresh cycles between the API and the real-time UI.

  2. Known Issue/Feature Request: We are aware of this difference, and there is an existing internal feature request related to improving the alignment between the API data and the UI representation for available funds. While we cannot provide a specific timeline for changes related to this FR, it signifies that this is recognized internally.

Recommendation:

  • While the calculation (adjusted_spending_limit_micros - amount_served_micros) provides a good estimate based on the available API data points, the Google Ads UI figure should generally be considered the more definitive representation of "Available funds" due to the additional factors it considers.

  • We recommend keeping an eye on our Release Notes and Google Ads Developer Blog for any future updates regarding budget fields in the API or changes related to this known discrepancy.

We understand this can be confusing, and appreciate you bringing it to our attention. Let us know if you have any further questions.

 

Thanks,
 
Google Logo
Bob Hancock
Google Ads API Team


Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5

[2025-04-17 19:33:54Z GMT] This message is in relation to case "ref:!00D1U01174p.!500Ht01pRXnS:ref" (ADR-00298815)



Reply all
Reply to author
Forward
0 new messages