Skip to main content

ListBillableObjectBindings

Retrieves the list of billable object bindings associated with the specified billing account.

import { cloudApi, serviceClients, Session } from "@yandex-cloud/nodejs-sdk";

const ListBillableObjectBindingsRequest =
cloudApi.billing.billing_account_service.ListBillableObjectBindingsRequest;

(async () => {
const authToken = process.env["YC_OAUTH_TOKEN"];
const session = new Session({ oauthToken: authToken });
const client = session.client(serviceClients.BillingAccountServiceClient);

const result = await client.listBillableObjectBindings(
ListBillableObjectBindingsRequest.fromPartial({
billingAccountId: "billingAccountId",
// pageSize: 0,
// pageToken: "pageToken"
})
);
console.log(result);
})();

ListBillableObjectBindingsRequest

billingAccountId : string

ID of the billing account to list associated billable object bindings. To get the billing account ID, use BillingAccountService.List request.

pageSize : int64

The maximum number of results per page to return. If the number of available results is larger than page_size, the service returns a ListBillableObjectBindingsResponse.next_page_token that can be used to get the next page of results in subsequent list requests.

pageToken : string

Page token. To get the next page of results, set page_token to the ListBillableObjectBindingsResponse.next_page_token returned by a previous list request.

ListBillableObjectBindingsResponse

billableObjectBindings : BillableObjectBinding

List of billable object bindings.

nextPageToken : string

This token allows you to get the next page of results for list requests. If the number of results is larger than ListBillableObjectBindingsRequest.page_size, use next_page_token as the value for the ListBillableObjectBindingsRequest.page_token query parameter in the next list request. Each subsequent list request will have its own next_page_token to continue paging through the results.

BillableObjectBinding

Represents a binding of the BillableObject to a BillingAccount.

effectiveTime : google.protobuf.Timestamp

Timestamp when binding was created.

billableObject : BillableObject

Object that is bound to billing account.

BillableObject

Represents a link to an object in other service. This object is being billed in the scope of a billing account.

id : string

ID of the object in other service.

type : string

Billable object type. Can be one of the following:

  • cloud