Object Queries

Retrieve an account

Retrieve the details of a specific Account object.

get/object-query/accounts/{key}

Path parameters

keystring required

Object ID or Number.

Query parameters

pageSizeinteger

The maximum number of results to return in a single page. If the specified pageSize is less than 1 or greater than 99, Zuora will return a 400 error.

cursorstring

A cursor for use in pagination. A cursor defines the starting place in a list. For instance, if you make a list request and receive 100 objects, ending with next_page=W3sib3JkZXJ=, your subsequent call can include cursor=W3sib3JkZXJ= in order to fetch the next page of the list.

sort[]string[]

A case-insensitive query parameter that specifies the sort order of the list, which can be either ascending (e.g. accountnumber.ASC) or descending (e.g. accountnumber.DESC). You cannot sort on properties in arrays. If the array-type properties are specified for the sort[] parameter, they are ignored.

expand[]string[]

Allows you to expand responses by including related object information in a single call.

filter[]string[]

A case-insensitive filter on the list.

fields[]string[]

A case-insensitive query parameter that allows you to specify which fields are returned in the response.

includeNullFieldsboolean

Specifies whether to include fields with the null value in the response.

  • If set to true, all fields will be returned in the response, including those with the null value.
  • If set to false, only fields with non-null values will be returned.

Headers

Idempotency-Keystring

Specify a unique idempotency key if you want to perform an idempotent POST or PATCH request. Do not use this header in other request types.

With this header specified, the Zuora server can identify subsequent retries of the same request using this value, which prevents the same operation from being performed multiple times by accident.

Accept-Encodingstring

Include the Accept-Encoding: gzip header to compress responses as a gzipped file. It can significantly reduce the bandwidth required for a response.

If specified, Zuora automatically compresses responses that contain over 1000 bytes of data, and the response contains a Content-Encoding header with the compression algorithm so that your client can decompress it.

Content-Encodingstring

Include the Content-Encoding: gzip header to compress a request. With this header specified, you should upload a gzipped file for the request payload instead of sending the JSON payload.

Zuora-Track-Idstring

A custom identifier for tracing the API call. If you set a value for this header, Zuora returns the same value in the response headers. This header enables you to associate your system process identifiers with Zuora API calls, to assist with troubleshooting in the event of an issue.

The value of this field must use the US-ASCII character set and must not include any of the following characters: colon (:), semicolon (;), double quote ("), and quote (').

Zuora-Entity-Idsstring

An entity ID. If you have Zuora Multi-entity enabled and the OAuth token is valid for more than one entity, you must use this header to specify which entity to perform the operation in. If the OAuth token is only valid for a single entity, or you do not have Zuora Multi-entity enabled, you should not set this header.

Zuora-Org-Idsstring

Comma separated IDs. If you have <a href="https://docs.zuora.com/en/zuora-platform/organization-and-entity-management/multi-org/overview-of-multi-org" target="_blank">Zuora Multi-Org</a> enabled, you can use this header to specify which orgs to perform the operation in. If you do not have Zuora Multi-Org enabled, you should not set this header.

The IDs must be a sub-set of the user's accessible orgs. If you specify an org that the user does not have access to, the operation fails. This header is important in Multi-Org (MO) setups because it defines the organization context under which the API should operate—mainly used for read access or data visibility filtering. If the header is not set, the operation is performed in scope of the user's accessible orgs.

Zuora-Versionstring

The minor API version.

For a list of available minor versions, see API upgrades.

Response

OK

idstring

The unique identifier of the account.

createdByIdstring

The unique identifier of the user who created the account.

createdDatestring date-time

The date and time when the account was created.

updatedByIdstring

The unique identifier of the user who last updated the account.

updatedDatestring date-time

The date and time when the account was last updated.

accountNumberstring

The account number that identifies the account.

additionalEmailAddressesstring

An additional email addresse to receive email notifications.

allowInvoiceEditboolean

Indicates whether associated invoices can be edited.

autoPayboolean

Indicates whether future payments are automatically collected when they are due during a payment run.

balancenumber double

The customer's total invoice balance minus credit balance.

batchstring

The alias name given to a batch. A string of 50 characters or less.

bcdSettingOption'ManualSet' | 'AutoSet'

Bill cycle day setting option. Indicates whether the account’s bill cycle day is managed manually or automatically.

  • ManualSet: The bill cycle day is explicitly set to a specific day of the month (1–31).
  • AutoSet: The bill cycle day is automatically determined by Zuora. The bill cycle day is assigned when the first subscription is created for the account.

This field is system-derived and read-only. Its value is automatically determined based on the billCycleDay field.

billCycleDayinteger

Billing cycle day (BCD), the day of the month when a bill run generates invoices for the account.

billToIdstring

The unique identifier of the bill-to contact associated with the account.

communicationProfileIdstring

The unique identifier of the communication profile that Zuora uses when sending notifications to the account's contacts.

creditBalancenumber double

The current credit balance on the account.

crmIdstring

External identifier of the account in a CRM system.

currencystring

A currency defined in the web-based UI administrative settings.

customerServiceRepNamestring

Name of the account's customer service representative, if applicable.

defaultPaymentMethodIdstring

ID of the default payment method for the account.

eInvoiceProfileIdstring

ID of the e-invoice profile for this account.

Note: This field is available only if you have the <a href="https://docs.zuora.com/en/zuora-billing/bill-your-customer/leverage-advanced-capabilities/e-invoicing/e-invoicing-overview" target="_blank">E-Invoicing</a> feature in Early Adopter phase enabled.

invoiceDeliveryPrefsEmailboolean

Indicates whether the customer wants to receive invoices through email.

invoiceDeliveryPrefsPrintboolean

Whether the customer wants to receive printed invoices, such as through postal mail.

invoiceTemplateIdstring

Invoice template ID, configured in Billing Settings in the Zuora UI.

lastInvoiceDatestring date

Date of the most recent invoice for the account; null if no invoice has ever been generated.

lastMetricsUpdatestring date-time

The date and time when account metrics are last updated, if the account is a partner account.

Note:

  • This field is available only if you have the <a href="https://knowledgecenter.zuora.com/Zuora_Billing/Manage_customer_accounts/AAA_Overview_of_customer_accounts/Reseller_Account" target="_blank">Reseller Account</a> feature enabled.
  • If you ever set the partnerAccount field to true for an account, the value of lastMetricsUpdate field is the time when the account metrics are last updated.
namestring

The name of the account.

notesstring

A string of up to 65,535 characters.

organizationIdstring

The unique identifier of the organization to which the account belongs.

parentIdstring

Identifier of the parent customer account for this Account object. The length is 32 characters. Use this field if you have <a href="https://knowledgecenter.zuora.com/Billing/Subscriptions/Customer_Accounts/A_Customer_Account_Introduction#Customer_Hierarchy" target="_blank">Customer Hierarchy</a> enabled.

partnerAccountboolean

Whether the customer account is a partner, distributor, or reseller.

Note: This field is available only if you have the <a href="https://knowledgecenter.zuora.com/Zuora_Billing/Manage_customer_accounts/AAA_Overview_of_customer_accounts/Reseller_Account" target="_blank">Reseller Account</a> feature enabled.

paymentMethodCascadingConsentboolean

true indicates the consent from your customer to use the Cascading Payment Method feature was collected. false indicates the consent was not collected and the Cascading Payment Method feature is not enabled.

purchaseOrderNumberstring

The purchase order number provided by your customer for services, products, or both purchased.

salesRepNamestring

Name of the account's sales representative, if applicable.

sequenceSetIdstring nullable

The ID of the billing document sequence set to assign to the customer account. The billing documents to generate for this account will adopt the prefix and starting document number configured in the sequence set. If a customer account has no assigned billing document sequence set, billing documents generated for this account adopt the prefix and starting document number from the default sequence set.

shipToIdstring

The unique identifier of the ship-to contact associated with the account.

soldToIdstring

The unique identifier of the sold-to contact associated with the account.

status'Active' | 'Draft' | 'Canceled'

The account status.

taxCompanyCodestring

Unique code that identifies a company account in Avalara. Note: This feature is in Limited Availability. If you wish to have access to the feature, submit a request at Zuora Global Support.

taxExemptCertificateIDstring

ID of the customer tax exemption certificate. Applicable if you use Zuora Tax or Connect tax engines.

taxExemptCertificateTypestring

Type of tax exemption certificate that the customer holds. Applicable if you use Zuora Tax or Connect tax engines.

taxExemptDescriptionstring

Description of the tax exemption certificate that the customer holds. Applicable if you use Zuora Tax or Connect tax engines.

taxExemptEffectiveDatestring date

Date when the customer tax exemption starts, in YYYY-MM-DD format. Applicable if you use Zuora Tax or Connect tax engines.

taxExemptEntityUseCodestring

A unique entity use code to apply exemptions in Avalara AvaTax. See <a href="https://developer.avalara.com/avatax/handling-tax-exempt-customers/" target="_blank">Exempt Transactions</a> for more details.

taxExemptExpirationDatestring date

Date when the customer tax exemption expires, in YYYY-MM-DD format. Applicable if you use Zuora Tax or Connect tax engines.

taxExemptIssuingJurisdictionstring

Jurisdiction in which the customer tax exemption certificate was issued.

taxExemptStatus'No' | 'Yes' | 'PendingVerification'

Status of the account tax exemption. Applicable if you use Zuora Tax or Connect tax engines. Required if you use Zuora Tax.

totalInvoiceBalancenumber double

Total balance of all posted invoices.

unappliedBalancenumber

Total unapplied balance in this currency.

vATIdstring

EU Value Added Tax ID.

mrrnumber

Monthly recurring revenue for the account.

totalDebitMemoBalancenumber double

Total balance of all posted debit memos.

unappliedCreditMemoAmountnumber double

The total unapplied amount of all posted credit memos in this currency.

creditMemoTemplateIdstring

ID of the credit memo template that is used to generate credit memos for the account.

debitMemoTemplateIdstring

ID of the debit memo template that is used to generate debit memos for the account.

paymentGatewaystring

The name of the payment gateway instance. If null or left unassigned, the account will use the default gateway.

paymentTermstring

A payment-terms indicator defined in the web-based UI administrative settings, for example, Net 30.

Example response

{
  "defaultPaymentMethod": {
    "paypalBaid": "I-1TJ3GAGG82Y9"
  },
  "payments": [
    {
      "currency": "USD",
      "paymentNumber": "P-00000028."
    }
  ],
  "paymentMethods": [
    {
      "paypalBaid": "I-1TJ3GAGG82Y9"
    }
  ]
}

Changes