- HTTP request
- Path parameters
- Query parameters
- Request body
- Response body
- Authorization Scopes
- Invoice
- InvoiceType
- AccountBudgetSummary
- AccountSummary
- Try it!
Returns all invoices associated with a billing setup, for a given month.
List of thrown errors: AuthenticationError AuthorizationError FieldError HeaderError InternalError InvoiceError QuotaError RequestError
HTTP request
GET https://googleads.googleapis.com/v12/customers/{customerId}/invoices
The URL uses gRPC Transcoding syntax.
Path parameters
Parameters | |
---|---|
customerId |
Required. The ID of the customer to fetch invoices for. |
Query parameters
Parameters | |
---|---|
billingSetup |
Required. The billing setup resource name of the requested invoices.
|
issueYear |
Required. The issue year to retrieve invoices, in yyyy format. Only invoices issued in 2019 or later can be retrieved. |
issueMonth |
Required. The issue month to retrieve invoices. |
Request body
The request body must be empty.
Response body
If successful, the response body contains data with the following structure:
Response message for InvoiceService.ListInvoices
.
JSON representation |
---|
{
"invoices": [
{
object ( |
Fields | |
---|---|
invoices[] |
The list of invoices that match the billing setup and time period. |
Authorization Scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/adwords
For more information, see the OAuth 2.0 Overview.
Invoice
An invoice. All invoice information is snapshotted to match the PDF invoice. For invoices older than the launch of InvoiceService, the snapshotted information may not match the PDF invoice.
JSON representation |
---|
{ "resourceName": string, "type": enum ( |
Fields | |
---|---|
resourceName |
Output only. The resource name of the invoice. Multiple customers can share a given invoice, so multiple resource names may point to the same invoice. Invoice resource names have the form:
|
type |
Output only. The type of invoice. |
serviceDateRange |
Output only. The service period date range of this invoice. The end date is inclusive. |
adjustmentsSubtotalAmountMicros |
Output only. The pretax subtotal amount of invoice level adjustments, in micros. |
adjustmentsTaxAmountMicros |
Output only. The sum of taxes on the invoice level adjustments, in micros. |
adjustmentsTotalAmountMicros |
Output only. The total amount of invoice level adjustments, in micros. |
regulatoryCostsSubtotalAmountMicros |
Output only. The pretax subtotal amount of invoice level regulatory costs, in micros. |
regulatoryCostsTaxAmountMicros |
Output only. The sum of taxes on the invoice level regulatory costs, in micros. |
regulatoryCostsTotalAmountMicros |
Output only. The total amount of invoice level regulatory costs, in micros. |
replacedInvoices[] |
Output only. The resource name of the original invoice(s) being rebilled or replaced by this invoice, if applicable. There might be multiple replaced invoices due to invoice consolidation. The replaced invoices may not belong to the same payments account. If
|
accountBudgetSummaries[] |
Output only. The list of summarized account budget information associated with this invoice. |
accountSummaries[] |
Output only. The list of summarized account information associated with this invoice. |
id |
Output only. The ID of the invoice. It appears on the invoice PDF as "Invoice number". |
billingSetup |
Output only. The resource name of this invoice's billing setup.
|
paymentsAccountId |
Output only. A 16 digit ID used to identify the payments account associated with the billing setup, for example, "1234-5678-9012-3456". It appears on the invoice PDF as "Billing Account Number". |
paymentsProfileId |
Output only. A 12 digit ID used to identify the payments profile associated with the billing setup, for example, "1234-5678-9012". It appears on the invoice PDF as "Billing ID". |
issueDate |
Output only. The issue date in yyyy-mm-dd format. It appears on the invoice PDF as either "Issue date" or "Invoice date". |
dueDate |
Output only. The due date in yyyy-mm-dd format. |
currencyCode |
Output only. The currency code. All costs are returned in this currency. A subset of the currency codes derived from the ISO 4217 standard is supported. |
subtotalAmountMicros |
Output only. The pretax subtotal amount, in micros. This equals the sum of the AccountBudgetSummary subtotal amounts, Invoice.adjustments_subtotal_amount_micros, and Invoice.regulatory_costs_subtotal_amount_micros. Starting with v6, the Invoice.regulatory_costs_subtotal_amount_micros is no longer included. |
taxAmountMicros |
Output only. The sum of all taxes on the invoice, in micros. This equals the sum of the AccountBudgetSummary tax amounts, plus taxes not associated with a specific account budget. |
totalAmountMicros |
Output only. The total amount, in micros. This equals the sum of Invoice.subtotal_amount_micros and Invoice.tax_amount_micros. Starting with v6, Invoice.regulatory_costs_subtotal_amount_micros is also added as it is no longer already included in Invoice.tax_amount_micros. |
correctedInvoice |
Output only. The resource name of the original invoice corrected, wrote off, or canceled by this invoice, if applicable. If
|
pdfUrl |
Output only. The URL to a PDF copy of the invoice. Users need to pass in their OAuth token to request the PDF with this URL. |
InvoiceType
The possible type of invoices.
Enums | |
---|---|
UNSPECIFIED |
Not specified. |
UNKNOWN |
Used for return value only. Represents value unknown in this version. |
CREDIT_MEMO |
An invoice with a negative amount. The account receives a credit. |
INVOICE |
An invoice with a positive amount. The account owes a balance. |
AccountBudgetSummary
Represents a summarized account budget billable cost.
JSON representation |
---|
{
"billableActivityDateRange": {
object ( |
Fields | |
---|---|
billableActivityDateRange |
Output only. The billable activity date range of the account budget, within the service date range of this invoice. The end date is inclusive. This can be different from the account budget's start and end time. |
customer |
Output only. The resource name of the customer associated with this account budget. This contains the customer ID, which appears on the invoice PDF as "Account ID". Customer resource names have the form:
|
customerDescriptiveName |
Output only. The descriptive name of the account budget's customer. It appears on the invoice PDF as "Account". |
accountBudget |
Output only. The resource name of the account budget associated with this summarized billable cost. AccountBudget resource names have the form:
|
accountBudgetName |
Output only. The name of the account budget. It appears on the invoice PDF as "Account budget". |
purchaseOrderNumber |
Output only. The purchase order number of the account budget. It appears on the invoice PDF as "Purchase order". |
subtotalAmountMicros |
Output only. The pretax subtotal amount attributable to this budget during the service period, in micros. |
taxAmountMicros |
Output only. The tax amount attributable to this budget during the service period, in micros. |
totalAmountMicros |
Output only. The total amount attributable to this budget during the service period, in micros. This equals the sum of the account budget subtotal amount and the account budget tax amount. |
servedAmountMicros |
Output only. Accessible only to customers on the allow-list. The pretax served amount attributable to this budget during the service period, in micros. This is only useful to reconcile invoice and delivery data. |
billedAmountMicros |
Output only. Accessible only to customers on the allow-list. The pretax billed amount attributable to this budget during the service period, in micros. This does not account for any adjustments. |
overdeliveryAmountMicros |
Output only. Accessible only to customers on the allow-list. The pretax overdelivery amount attributable to this budget during the service period, in micros (negative value). |
invalidActivityAmountMicros |
Output only. Accessible only to customers on the allow-list. The pretax invalid activity amount attributable to this budget in previous months, in micros (negative value). |
AccountSummary
Represents a summarized view at account level. AccountSummary fields are accessible only to customers on the allow-list.
JSON representation |
---|
{ "customer": string, "billingCorrectionSubtotalAmountMicros": string, "billingCorrectionTaxAmountMicros": string, "billingCorrectionTotalAmountMicros": string, "couponAdjustmentSubtotalAmountMicros": string, "couponAdjustmentTaxAmountMicros": string, "couponAdjustmentTotalAmountMicros": string, "excessCreditAdjustmentSubtotalAmountMicros": string, "excessCreditAdjustmentTaxAmountMicros": string, "excessCreditAdjustmentTotalAmountMicros": string, "regulatoryCostsSubtotalAmountMicros": string, "regulatoryCostsTaxAmountMicros": string, "regulatoryCostsTotalAmountMicros": string, "subtotalAmountMicros": string, "taxAmountMicros": string, "totalAmountMicros": string } |
Fields | |
---|---|
customer |
Output only. The account associated with the account summary. |
billingCorrectionSubtotalAmountMicros |
Output only. Pretax billing correction subtotal amount, in micros. |
billingCorrectionTaxAmountMicros |
Output only. Tax on billing correction, in micros. |
billingCorrectionTotalAmountMicros |
Output only. Total billing correction amount, in micros. |
couponAdjustmentSubtotalAmountMicros |
Output only. Pretax coupon adjustment subtotal amount, in micros. |
couponAdjustmentTaxAmountMicros |
Output only. Tax on coupon adjustment, in micros. |
couponAdjustmentTotalAmountMicros |
Output only. Total coupon adjustment amount, in micros. |
excessCreditAdjustmentSubtotalAmountMicros |
Output only. Pretax excess credit adjustment subtotal amount, in micros. |
excessCreditAdjustmentTaxAmountMicros |
Output only. Tax on excess credit adjustment, in micros. |
excessCreditAdjustmentTotalAmountMicros |
Output only. Total excess credit adjustment amount, in micros. |
regulatoryCostsSubtotalAmountMicros |
Output only. Pretax regulatory costs subtotal amount, in micros. |
regulatoryCostsTaxAmountMicros |
Output only. Tax on regulatory costs, in micros. |
regulatoryCostsTotalAmountMicros |
Output only. Total regulatory costs amount, in micros. |
subtotalAmountMicros |
Output only. Total pretax subtotal amount attributable to the account during the service period, in micros. |
taxAmountMicros |
Output only. Total tax amount attributable to the account during the service period, in micros. |
totalAmountMicros |
Output only. Total amount attributable to the account during the service period, in micros. This equals the sum of the subtotalAmountMicros and taxAmountMicros. |