CloudChannelServiceClient

CloudChannelServiceClient

CloudChannelService lets Google cloud resellers and distributors manage their customers, channel partners, entitlements, and reports.

Using this service:

  1. Resellers and distributors can manage a customer entity.
  2. Distributors can register an authorized reseller in their channel and provide them with delegated admin access.
  3. Resellers and distributors can manage customer entitlements.

CloudChannelService exposes the following resources:

  • Customers: An entity-usually an enterprise-managed by a reseller or distributor.

  • Entitlements: An entity that provides a customer with the means to use a service. Entitlements are created or updated as a result of a successful fulfillment.

  • ChannelPartnerLinks: An entity that identifies links between distributors and their indirect resellers in a channel.

Constructor

new CloudChannelServiceClient(optionsopt, gaxInstanceopt)

Construct an instance of CloudChannelServiceClient.

Parameters:
Name Type Attributes Description
options object <optional>

The configuration object. The options accepted by the constructor are described in detail in this document. The common options are:

Properties
Name Type Attributes Description
credentials object <optional>

Credentials object.

Properties
Name Type Attributes Description
client_email string <optional>
private_key string <optional>
email string <optional>

Account email address. Required when using a .pem or .p12 keyFilename.

keyFilename string <optional>

Full path to the a .json, .pem, or .p12 key downloaded from the Google Developers Console. If you provide a path to a JSON file, the projectId option below is not necessary. NOTE: .pem and .p12 require you to specify options.email as well.

port number <optional>

The port on which to connect to the remote host.

projectId string <optional>

The project ID from the Google Developer's Console, e.g. 'grape-spaceship-123'. We will also check the environment variable GCLOUD_PROJECT for your project ID. If your app is running in an environment which supports Application Default Credentials, your project ID will be detected automatically.

apiEndpoint string <optional>

The domain name of the API remote host.

clientConfig gax.ClientConfig <optional>

Client configuration override. Follows the structure of gapicConfig.

fallback boolean <optional>

Use HTTP/1.1 REST mode. For more information, please check the documentation.

gaxInstance gax <optional>

loaded instance of google-gax. Useful if you need to avoid loading the default gRPC version and want to use the fallback HTTP implementation. Load only fallback version and pass it to the constructor: const gax = require('google-gax/build/src/fallback'); // avoids loading google-gax with gRPC const client = new CloudChannelServiceClient({fallback: true}, gax);

Members

apiEndpoint

The DNS address for this API service - same as servicePath(), exists for compatibility reasons.

port

The port for this API service.

scopes

The scopes needed to make gRPC calls for every method defined in this service.

servicePath

The DNS address for this API service.

Methods

billingAccountPath(account, billing_account) → {string}

Return a fully-qualified billingAccount resource name string.

Parameters:
Name Type Description
account string
billing_account string
Returns:
Type Description
string

Resource name string.

cancelOperation(request, optionsopt, callbackopt) → {Promise}

Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Description
name string

The name of the operation resource to be cancelled.

options Object <optional>

Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See gax.CallOptions for the details.

callback function <optional>

The function which will be called with the result of the API call.

Returns:
Type Description
Promise
  • The promise which resolves when API call finishes. The promise has a method named "cancel" which cancels the ongoing API call.
Example
```
const client = longrunning.operationsClient();
await client.cancelOperation({name: ''});
```

channelPartnerLinkPath(account, channel_partner_link) → {string}

Return a fully-qualified channelPartnerLink resource name string.

Parameters:
Name Type Description
account string
channel_partner_link string
Returns:
Type Description
string

Resource name string.

channelPartnerRepricingConfigPath(account, channel_partner, channel_partner_repricing_config) → {string}

Return a fully-qualified channelPartnerRepricingConfig resource name string.

Parameters:
Name Type Description
account string
channel_partner string
channel_partner_repricing_config string
Returns:
Type Description
string

Resource name string.

(async) checkActivateEntitlementProgress(name) → {Promise}

Check the status of the long running operation returned by activateEntitlement().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the entitlement to activate.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callActivateEntitlement() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const [operation] = await channelClient.activateEntitlement(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callActivateEntitlement();

(async) checkCancelEntitlementProgress(name) → {Promise}

Check the status of the long running operation returned by cancelEntitlement().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the entitlement to cancel.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callCancelEntitlement() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const [operation] = await channelClient.cancelEntitlement(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCancelEntitlement();

(async) checkChangeOfferProgress(name) → {Promise}

Check the status of the long running operation returned by changeOffer().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the entitlement to update.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Required. New Offer.
   *  Format: accounts/{account_id}/offers/{offer_id}.
   */
  // const offer = 'abc123'
  /**
   *  Optional. Parameters needed to purchase the Offer. To view the available
   *  Parameters refer to the
   *  Offer.parameter_definitions google.cloud.channel.v1.Offer.parameter_definitions 
   *  from the desired offer.
   */
  // const parameters = [1,2,3,4]
  /**
   *  Optional. Purchase order id provided by the reseller.
   */
  // const purchaseOrderId = 'abc123'
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'
  /**
   *  Optional. The billing account resource name that is used to pay for this
   *  entitlement when setting up billing on a trial subscription.
   *  This field is only relevant for multi-currency accounts. It should be
   *  left empty for single currency accounts.
   */
  // const billingAccount = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callChangeOffer() {
    // Construct request
    const request = {
      name,
      offer,
    };

    // Run request
    const [operation] = await channelClient.changeOffer(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callChangeOffer();

(async) checkChangeParametersProgress(name) → {Promise}

Check the status of the long running operation returned by changeParameters().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The name of the entitlement to update.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Required. Entitlement parameters to update. You can only change editable
   *  parameters.
   *  To view the available Parameters for a request, refer to the
   *  Offer.parameter_definitions google.cloud.channel.v1.Offer.parameter_definitions 
   *  from the desired offer.
   */
  // const parameters = [1,2,3,4]
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'
  /**
   *  Optional. Purchase order ID provided by the reseller.
   */
  // const purchaseOrderId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callChangeParameters() {
    // Construct request
    const request = {
      name,
      parameters,
    };

    // Run request
    const [operation] = await channelClient.changeParameters(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callChangeParameters();

(async) checkChangeRenewalSettingsProgress(name) → {Promise}

Check the status of the long running operation returned by changeRenewalSettings().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The name of the entitlement to update.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Required. New renewal settings.
   */
  // const renewalSettings = {}
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callChangeRenewalSettings() {
    // Construct request
    const request = {
      name,
      renewalSettings,
    };

    // Run request
    const [operation] = await channelClient.changeRenewalSettings(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callChangeRenewalSettings();

(async) checkCreateEntitlementProgress(name) → {Promise}

Check the status of the long running operation returned by createEntitlement().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller's customer account in which to
   *  create the entitlement. Parent uses the format:
   *  accounts/{account_id}/customers/{customer_id}
   */
  // const parent = 'abc123'
  /**
   *  Required. The entitlement to create.
   */
  // const entitlement = {}
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callCreateEntitlement() {
    // Construct request
    const request = {
      parent,
      entitlement,
    };

    // Run request
    const [operation] = await channelClient.createEntitlement(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callCreateEntitlement();

(async) checkProvisionCloudIdentityProgress(name) → {Promise}

Check the status of the long running operation returned by provisionCloudIdentity().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. Resource name of the customer.
   *  Format: accounts/{account_id}/customers/{customer_id}
   */
  // const customer = 'abc123'
  /**
   *  CloudIdentity-specific customer information.
   */
  // const cloudIdentityInfo = {}
  /**
   *  Admin user information.
   */
  // const user = {}
  /**
   *  Validate the request and preview the review, but do not post it.
   */
  // const validateOnly = true

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callProvisionCloudIdentity() {
    // Construct request
    const request = {
      customer,
    };

    // Run request
    const [operation] = await channelClient.provisionCloudIdentity(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callProvisionCloudIdentity();

(async) checkStartPaidServiceProgress(name) → {Promise}

Check the status of the long running operation returned by startPaidService().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The name of the entitlement to start a paid service for.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callStartPaidService() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const [operation] = await channelClient.startPaidService(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callStartPaidService();

(async) checkSuspendEntitlementProgress(name) → {Promise}

Check the status of the long running operation returned by suspendEntitlement().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the entitlement to suspend.
   *  Name uses the format:
   *  accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   */
  // const name = 'abc123'
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callSuspendEntitlement() {
    // Construct request
    const request = {
      name,
    };

    // Run request
    const [operation] = await channelClient.suspendEntitlement(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callSuspendEntitlement();

(async) checkTransferEntitlementsProgress(name) → {Promise}

Check the status of the long running operation returned by transferEntitlements().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller's customer account that will
   *  receive transferred entitlements. Parent uses the format:
   *  accounts/{account_id}/customers/{customer_id}
   */
  // const parent = 'abc123'
  /**
   *  Required. The new entitlements to create or transfer.
   */
  // const entitlements = [1,2,3,4]
  /**
   *  The super admin of the resold customer generates this token to
   *  authorize a reseller to access their Cloud Identity and purchase
   *  entitlements on their behalf. You can omit this token after authorization.
   *  See https://support.google.com/a/answer/7643790 for more details.
   */
  // const authToken = 'abc123'
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callTransferEntitlements() {
    // Construct request
    const request = {
      parent,
      entitlements,
    };

    // Run request
    const [operation] = await channelClient.transferEntitlements(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callTransferEntitlements();

(async) checkTransferEntitlementsToGoogleProgress(name) → {Promise}

Check the status of the long running operation returned by transferEntitlementsToGoogle().

Parameters:
Name Type Description
name String

The operation name that will be passed.

Returns:
Type Description
Promise
  • The promise which resolves to an object. The decoded operation object has result and metadata field to get information from. Please see the documentation for more details and examples.
Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller's customer account where the
   *  entitlements transfer from. Parent uses the format:
   *  accounts/{account_id}/customers/{customer_id}
   */
  // const parent = 'abc123'
  /**
   *  Required. The entitlements to transfer to Google.
   */
  // const entitlements = [1,2,3,4]
  /**
   *  Optional. You can specify an optional unique request ID, and if you need to
   *  retry your request, the server will know to ignore the request if it's
   *  complete.
   *  For example, you make an initial request and the request times out. If you
   *  make the request again with the same request ID, the server can check if
   *  it received the original operation with the same request ID. If it did, it
   *  will ignore the second request.
   *  The request ID must be a valid UUID (https://tools.ietf.org/html/rfc4122)
   *  with the exception that zero UUID is not supported
   *  (`00000000-0000-0000-0000-000000000000`).
   */
  // const requestId = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callTransferEntitlementsToGoogle() {
    // Construct request
    const request = {
      parent,
      entitlements,
    };

    // Run request
    const [operation] = await channelClient.transferEntitlementsToGoogle(request);
    const [response] = await operation.promise();
    console.log(response);
  }

  callTransferEntitlementsToGoogle();

close() → {Promise}

Terminate the gRPC channel and close the client.

The client will no longer be usable and all future behavior is undefined.

Returns:
Type Description
Promise

A promise that resolves when the client is closed.

customerPath(account, customer) → {string}

Return a fully-qualified customer resource name string.

Parameters:
Name Type Description
account string
customer string
Returns:
Type Description
string

Resource name string.

customerRepricingConfigPath(account, customer, customer_repricing_config) → {string}

Return a fully-qualified customerRepricingConfig resource name string.

Parameters:
Name Type Description
account string
customer string
customer_repricing_config string
Returns:
Type Description
string

Resource name string.

deleteOperation(request, optionsopt, callbackopt) → {Promise}

Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Description
name string

The name of the operation resource to be deleted.

options Object <optional>

Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See gax.CallOptions for the details.

callback function <optional>

The function which will be called with the result of the API call.

Returns:
Type Description
Promise
  • The promise which resolves when API call finishes. The promise has a method named "cancel" which cancels the ongoing API call.
Example
```
const client = longrunning.operationsClient();
await client.deleteOperation({name: ''});
```

entitlementPath(account, customer, entitlement) → {string}

Return a fully-qualified entitlement resource name string.

Parameters:
Name Type Description
account string
customer string
entitlement string
Returns:
Type Description
string

Resource name string.

getOperation(request, optionsopt, callbackopt) → {Promise}

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Description
name string

The name of the operation resource.

options Object <optional>

Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See gax.CallOptions for the details.

callback function <optional>

The function which will be called with the result of the API call.

The second parameter to the callback is an object representing google.longrunning.Operation.

Returns:
Type Description
Promise
  • The promise which resolves to an array. The first element of the array is an object representing google.longrunning.Operation. The promise has a method named "cancel" which cancels the ongoing API call.
Example
```
const client = longrunning.operationsClient();
const name = '';
const [response] = await client.getOperation({name});
// doThingsWith(response)
```

getProjectId() → {Promise}

Return the project ID used by this class.

Returns:
Type Description
Promise

A promise that resolves to string containing the project ID.

initialize() → {Promise}

Initialize the client. Performs asynchronous operations (such as authentication) and prepares the client. This function will be called automatically when any class method is called for the first time, but if you need to initialize it before calling an actual method, feel free to call initialize() directly.

You can await on this method if you want to make sure the client is initialized.

Returns:
Type Description
Promise

A promise that resolves to an authenticated service stub.

listChannelPartnerLinksAsync(request, optionsopt) → {Object}

Equivalent to listChannelPartnerLinks, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller account for listing channel partner links. Parent uses the format: accounts/{account_id}

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, server will pick a default size (25). The maximum value is 200; the server will coerce values above 200.

pageToken string <optional>

Optional. A token for a page of results other than the first page. Obtained using ListChannelPartnerLinksResponse.next_page_token of the previous CloudChannelService.ListChannelPartnerLinks call.

view google.cloud.channel.v1.ChannelPartnerLinkView <optional>

Optional. The level of granularity the ChannelPartnerLink will display.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing ChannelPartnerLink. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller account for listing channel
   *  partner links. Parent uses the format: accounts/{account_id}
   */
  // const parent = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, server will pick a default size (25). The
   *  maximum value is 200; the server will coerce values above 200.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   *  Obtained using
   *  ListChannelPartnerLinksResponse.next_page_token google.cloud.channel.v1.ListChannelPartnerLinksResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListChannelPartnerLinks google.cloud.channel.v1.CloudChannelService.ListChannelPartnerLinks 
   *  call.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The level of granularity the ChannelPartnerLink will display.
   */
  // const view = {}

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListChannelPartnerLinks() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listChannelPartnerLinksAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListChannelPartnerLinks();

listChannelPartnerLinksStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller account for listing channel partner links. Parent uses the format: accounts/{account_id}

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, server will pick a default size (25). The maximum value is 200; the server will coerce values above 200.

pageToken string <optional>

Optional. A token for a page of results other than the first page. Obtained using ListChannelPartnerLinksResponse.next_page_token of the previous CloudChannelService.ListChannelPartnerLinks call.

view google.cloud.channel.v1.ChannelPartnerLinkView <optional>

Optional. The level of granularity the ChannelPartnerLink will display.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing ChannelPartnerLink on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listChannelPartnerLinksAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listChannelPartnerRepricingConfigsAsync(request, optionsopt) → {Object}

Equivalent to listChannelPartnerRepricingConfigs, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the account's ChannelPartnerLink. Parent uses the format: accounts/{account_id}/channelPartnerLinks/{channel_partner_id}. Supports accounts/{account_id}/channelPartnerLinks/- to retrieve configs for all channel partners.

pageSize number <optional>

Optional. The maximum number of repricing configs to return. The service may return fewer than this value. If unspecified, returns a maximum of 50 rules. The maximum value is 100; values above 100 will be coerced to 100.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListChannelPartnerRepricingConfigsResponse.next_page_token of the previous CloudChannelService.ListChannelPartnerRepricingConfigs call.

filter string <optional>

Optional. A filter for [CloudChannelService.ListChannelPartnerRepricingConfigs] results (channel_partner_link only). You can use this filter when you support a BatchGet-like query. To use the filter, you must set parent=accounts/{account_id}/channelPartnerLinks/-.

Example: channel_partner_link = accounts/account_id/channelPartnerLinks/c1 OR channel_partner_link = accounts/account_id/channelPartnerLinks/c2.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing ChannelPartnerRepricingConfig. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the account's
   *  ChannelPartnerLink google.cloud.channel.v1.ChannelPartnerLink. Parent
   *  uses the format:
   *  accounts/{account_id}/channelPartnerLinks/{channel_partner_id}.
   *  Supports accounts/{account_id}/channelPartnerLinks/- to retrieve configs
   *  for all channel partners.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of repricing configs to return. The service
   *  may return fewer than this value. If unspecified, returns a maximum of 50
   *  rules. The maximum value is 100; values above 100 will be coerced to 100.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token identifying a page of results beyond the first page.
   *  Obtained through
   *  ListChannelPartnerRepricingConfigsResponse.next_page_token google.cloud.channel.v1.ListChannelPartnerRepricingConfigsResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListChannelPartnerRepricingConfigs google.cloud.channel.v1.CloudChannelService.ListChannelPartnerRepricingConfigs 
   *  call.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. A filter for
   *  CloudChannelService.ListChannelPartnerRepricingConfigs  results
   *  (channel_partner_link only). You can use this filter when you support a
   *  BatchGet-like query. To use the filter, you must set
   *  `parent=accounts/{account_id}/channelPartnerLinks/-`.
   *  Example: `channel_partner_link =
   *  accounts/account_id/channelPartnerLinks/c1` OR `channel_partner_link =
   *  accounts/account_id/channelPartnerLinks/c2`.
   */
  // const filter = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListChannelPartnerRepricingConfigs() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listChannelPartnerRepricingConfigsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListChannelPartnerRepricingConfigs();

listChannelPartnerRepricingConfigsStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the account's ChannelPartnerLink. Parent uses the format: accounts/{account_id}/channelPartnerLinks/{channel_partner_id}. Supports accounts/{account_id}/channelPartnerLinks/- to retrieve configs for all channel partners.

pageSize number <optional>

Optional. The maximum number of repricing configs to return. The service may return fewer than this value. If unspecified, returns a maximum of 50 rules. The maximum value is 100; values above 100 will be coerced to 100.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListChannelPartnerRepricingConfigsResponse.next_page_token of the previous CloudChannelService.ListChannelPartnerRepricingConfigs call.

filter string <optional>

Optional. A filter for [CloudChannelService.ListChannelPartnerRepricingConfigs] results (channel_partner_link only). You can use this filter when you support a BatchGet-like query. To use the filter, you must set parent=accounts/{account_id}/channelPartnerLinks/-.

Example: channel_partner_link = accounts/account_id/channelPartnerLinks/c1 OR channel_partner_link = accounts/account_id/channelPartnerLinks/c2.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing ChannelPartnerRepricingConfig on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listChannelPartnerRepricingConfigsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listCustomerRepricingConfigsAsync(request, optionsopt) → {Object}

Equivalent to listCustomerRepricingConfigs, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the customer. Parent uses the format: accounts/{account_id}/customers/{customer_id}. Supports accounts/{account_id}/customers/- to retrieve configs for all customers.

pageSize number <optional>

Optional. The maximum number of repricing configs to return. The service may return fewer than this value. If unspecified, returns a maximum of 50 rules. The maximum value is 100; values above 100 will be coerced to 100.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListCustomerRepricingConfigsResponse.next_page_token of the previous CloudChannelService.ListCustomerRepricingConfigs call.

filter string <optional>

Optional. A filter for [CloudChannelService.ListCustomerRepricingConfigs] results (customer only). You can use this filter when you support a BatchGet-like query. To use the filter, you must set parent=accounts/{account_id}/customers/-.

Example: customer = accounts/account_id/customers/c1 OR customer = accounts/account_id/customers/c2.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing CustomerRepricingConfig. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the customer.
   *  Parent uses the format: accounts/{account_id}/customers/{customer_id}.
   *  Supports accounts/{account_id}/customers/- to retrieve configs for all
   *  customers.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of repricing configs to return. The service
   *  may return fewer than this value. If unspecified, returns a maximum of 50
   *  rules. The maximum value is 100; values above 100 will be coerced to 100.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token identifying a page of results beyond the first page.
   *  Obtained through
   *  ListCustomerRepricingConfigsResponse.next_page_token google.cloud.channel.v1.ListCustomerRepricingConfigsResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListCustomerRepricingConfigs google.cloud.channel.v1.CloudChannelService.ListCustomerRepricingConfigs 
   *  call.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. A filter for CloudChannelService.ListCustomerRepricingConfigs 
   *  results (customer only). You can use this filter when you support
   *  a BatchGet-like query.
   *  To use the filter, you must set `parent=accounts/{account_id}/customers/-`.
   *  Example: customer = accounts/account_id/customers/c1 OR
   *  customer = accounts/account_id/customers/c2.
   */
  // const filter = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListCustomerRepricingConfigs() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listCustomerRepricingConfigsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListCustomerRepricingConfigs();

listCustomerRepricingConfigsStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the customer. Parent uses the format: accounts/{account_id}/customers/{customer_id}. Supports accounts/{account_id}/customers/- to retrieve configs for all customers.

pageSize number <optional>

Optional. The maximum number of repricing configs to return. The service may return fewer than this value. If unspecified, returns a maximum of 50 rules. The maximum value is 100; values above 100 will be coerced to 100.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListCustomerRepricingConfigsResponse.next_page_token of the previous CloudChannelService.ListCustomerRepricingConfigs call.

filter string <optional>

Optional. A filter for [CloudChannelService.ListCustomerRepricingConfigs] results (customer only). You can use this filter when you support a BatchGet-like query. To use the filter, you must set parent=accounts/{account_id}/customers/-.

Example: customer = accounts/account_id/customers/c1 OR customer = accounts/account_id/customers/c2.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing CustomerRepricingConfig on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listCustomerRepricingConfigsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listCustomersAsync(request, optionsopt) → {Object}

Equivalent to listCustomers, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller account to list customers from. Parent uses the format: accounts/{account_id}.

pageSize number <optional>

Optional. The maximum number of customers to return. The service may return fewer than this value. If unspecified, returns at most 10 customers. The maximum value is 50.

pageToken string <optional>

Optional. A token identifying a page of results other than the first page. Obtained through ListCustomersResponse.next_page_token of the previous CloudChannelService.ListCustomers call.

filter string <optional>

Optional. Filters applied to the [CloudChannelService.ListCustomers] results. See https://cloud.google.com/channel/docs/concepts/google-cloud/filter-customers for more information.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing Customer. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller account to list customers from.
   *  Parent uses the format: accounts/{account_id}.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of customers to return. The service may return
   *  fewer than this value. If unspecified, returns at most 10 customers. The
   *  maximum value is 50.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token identifying a page of results other than the first page.
   *  Obtained through
   *  ListCustomersResponse.next_page_token google.cloud.channel.v1.ListCustomersResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListCustomers google.cloud.channel.v1.CloudChannelService.ListCustomers 
   *  call.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. Filters applied to the CloudChannelService.ListCustomers 
   *  results. See
   *  https://cloud.google.com/channel/docs/concepts/google-cloud/filter-customers
   *  for more information.
   */
  // const filter = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListCustomers() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listCustomersAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListCustomers();

listCustomersStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller account to list customers from. Parent uses the format: accounts/{account_id}.

pageSize number <optional>

Optional. The maximum number of customers to return. The service may return fewer than this value. If unspecified, returns at most 10 customers. The maximum value is 50.

pageToken string <optional>

Optional. A token identifying a page of results other than the first page. Obtained through ListCustomersResponse.next_page_token of the previous CloudChannelService.ListCustomers call.

filter string <optional>

Optional. Filters applied to the [CloudChannelService.ListCustomers] results. See https://cloud.google.com/channel/docs/concepts/google-cloud/filter-customers for more information.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing Customer on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listCustomersAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listEntitlementChangesAsync(request, optionsopt) → {Object}

Equivalent to listEntitlementChanges, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the entitlement for which to list entitlement changes. The - wildcard may be used to match entitlements across a customer. Formats:

* accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
* accounts/{account_id}/customers/{customer_id}/entitlements/-
pageSize number <optional>

Optional. The maximum number of entitlement changes to return. The service may return fewer than this value. If unspecified, returns at most 10 entitlement changes. The maximum value is 50; the server will coerce values above 50.

pageToken string <optional>

Optional. A page token, received from a previous CloudChannelService.ListEntitlementChanges call. Provide this to retrieve the subsequent page.

When paginating, all other parameters provided to CloudChannelService.ListEntitlementChanges must match the call that provided the page token.

filter string <optional>

Optional. Filters applied to the list results.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing EntitlementChange. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the entitlement for which to list
   *  entitlement changes. The `-` wildcard may be used to match entitlements
   *  across a customer. Formats:
   *    * accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
   *    * accounts/{account_id}/customers/{customer_id}/entitlements/-
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of entitlement changes to return. The service
   *  may return fewer than this value. If unspecified, returns at most 10
   *  entitlement changes. The maximum value is 50; the server will coerce values
   *  above 50.
   */
  // const pageSize = 1234
  /**
   *  Optional. A page token, received from a previous
   *  CloudChannelService.ListEntitlementChanges google.cloud.channel.v1.CloudChannelService.ListEntitlementChanges 
   *  call. Provide this to retrieve the subsequent page.
   *  When paginating, all other parameters provided to
   *  CloudChannelService.ListEntitlementChanges google.cloud.channel.v1.CloudChannelService.ListEntitlementChanges 
   *  must match the call that provided the page token.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. Filters applied to the list results.
   */
  // const filter = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListEntitlementChanges() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listEntitlementChangesAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListEntitlementChanges();

listEntitlementChangesStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the entitlement for which to list entitlement changes. The - wildcard may be used to match entitlements across a customer. Formats:

* accounts/{account_id}/customers/{customer_id}/entitlements/{entitlement_id}
* accounts/{account_id}/customers/{customer_id}/entitlements/-
pageSize number <optional>

Optional. The maximum number of entitlement changes to return. The service may return fewer than this value. If unspecified, returns at most 10 entitlement changes. The maximum value is 50; the server will coerce values above 50.

pageToken string <optional>

Optional. A page token, received from a previous CloudChannelService.ListEntitlementChanges call. Provide this to retrieve the subsequent page.

When paginating, all other parameters provided to CloudChannelService.ListEntitlementChanges must match the call that provided the page token.

filter string <optional>

Optional. Filters applied to the list results.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing EntitlementChange on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listEntitlementChangesAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listEntitlementsAsync(request, optionsopt) → {Object}

Equivalent to listEntitlements, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller's customer account to list entitlements for. Parent uses the format: accounts/{account_id}/customers/{customer_id}

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, return at most 50 entitlements. The maximum value is 100; the server will coerce values above 100.

pageToken string <optional>

Optional. A token for a page of results other than the first page. Obtained using ListEntitlementsResponse.next_page_token of the previous CloudChannelService.ListEntitlements call.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing Entitlement. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller's customer account to list
   *  entitlements for.
   *  Parent uses the format: accounts/{account_id}/customers/{customer_id}
   */
  // const parent = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, return at most 50 entitlements. The maximum
   *  value is 100; the server will coerce values above 100.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   *  Obtained using
   *  ListEntitlementsResponse.next_page_token google.cloud.channel.v1.ListEntitlementsResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListEntitlements google.cloud.channel.v1.CloudChannelService.ListEntitlements 
   *  call.
   */
  // const pageToken = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListEntitlements() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listEntitlementsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListEntitlements();

listEntitlementsStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller's customer account to list entitlements for. Parent uses the format: accounts/{account_id}/customers/{customer_id}

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, return at most 50 entitlements. The maximum value is 100; the server will coerce values above 100.

pageToken string <optional>

Optional. A token for a page of results other than the first page. Obtained using ListEntitlementsResponse.next_page_token of the previous CloudChannelService.ListEntitlements call.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing Entitlement on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listEntitlementsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listOffersAsync(request, optionsopt) → {Object}

Equivalent to listOffers, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller account from which to list Offers. Parent uses the format: accounts/{account_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 500 Offers. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

filter string <optional>

Optional. The expression to filter results by name (name of the Offer), sku.name (name of the SKU), or sku.product.name (name of the Product). Example 1: sku.product.name=products/p1 AND sku.name!=products/p1/skus/s1 Example 2: name=accounts/a1/offers/o1

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

showFutureOffers boolean <optional>

Optional. A boolean flag that determines if a response returns future offers 30 days from now. If the show_future_offers is true, the response will only contain offers that are scheduled to be available 30 days from now.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing Offer. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller account from which to list
   *  Offers. Parent uses the format: accounts/{account_id}.
   */
  // const parent = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, returns at most 500 Offers. The maximum value is
   *  1000; the server will coerce values above 1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The expression to filter results by name (name of
   *  the Offer), sku.name (name of the SKU), or sku.product.name (name of the
   *  Product).
   *  Example 1: sku.product.name=products/p1 AND sku.name!=products/p1/skus/s1
   *  Example 2: name=accounts/a1/offers/o1
   */
  // const filter = 'abc123'
  /**
   *  Optional. The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   */
  // const languageCode = 'abc123'
  /**
   *  Optional. A boolean flag that determines if a response returns future
   *  offers 30 days from now. If the show_future_offers is true, the response
   *  will only contain offers that are scheduled to be available 30 days from
   *  now.
   */
  // const showFutureOffers = true

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListOffers() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listOffersAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListOffers();

listOffersStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the reseller account from which to list Offers. Parent uses the format: accounts/{account_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 500 Offers. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

filter string <optional>

Optional. The expression to filter results by name (name of the Offer), sku.name (name of the SKU), or sku.product.name (name of the Product). Example 1: sku.product.name=products/p1 AND sku.name!=products/p1/skus/s1 Example 2: name=accounts/a1/offers/o1

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

showFutureOffers boolean <optional>

Optional. A boolean flag that determines if a response returns future offers 30 days from now. If the show_future_offers is true, the response will only contain offers that are scheduled to be available 30 days from now.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing Offer on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listOffersAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listOperationsAsync(request, optionsopt) → {Object}

Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED. Returns an iterable object.

For-await-of syntax is used with the iterable to recursively get response element on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
name string

The name of the operation collection.

filter string

The standard list filter.

pageSize number <optional>

The maximum number of resources contained in the underlying API response. If page streaming is performed per-resource, this parameter does not affect the return value. If page streaming is performed per-page, this determines the maximum number of resources in a page.

options Object <optional>

Optional parameters. You can override the default settings for this call, e.g, timeout, retries, paginations, etc. See gax.CallOptions for the details.

Returns:
Type Description
Object

An iterable Object that conforms to iteration protocols.

Example
```
const client = longrunning.operationsClient();
for await (const response of client.listOperationsAsync(request));
// doThingsWith(response)
```

listProductsAsync(request, optionsopt) → {Object}

Equivalent to listProducts, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
account string

Required. The resource name of the reseller account. Format: accounts/{account_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 Products. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing Product. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the reseller account.
   *  Format: accounts/{account_id}.
   */
  // const account = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, returns at most 100 Products. The maximum value
   *  is 1000; the server will coerce values above 1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   */
  // const languageCode = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListProducts() {
    // Construct request
    const request = {
      account,
    };

    // Run request
    const iterable = await channelClient.listProductsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListProducts();

listProductsStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
account string

Required. The resource name of the reseller account. Format: accounts/{account_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 Products. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing Product on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listProductsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listPurchasableOffersAsync(request, optionsopt) → {Object}

Equivalent to listPurchasableOffers, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
createEntitlementPurchase google.cloud.channel.v1.ListPurchasableOffersRequest.CreateEntitlementPurchase

List Offers for CreateEntitlement purchase.

changeOfferPurchase google.cloud.channel.v1.ListPurchasableOffersRequest.ChangeOfferPurchase

List Offers for ChangeOffer purchase.

customer string

Required. The resource name of the customer to list Offers for. Format: accounts/{account_id}/customers/{customer_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 Offers. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing PurchasableOffer. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  List Offers for CreateEntitlement purchase.
   */
  // const createEntitlementPurchase = {}
  /**
   *  List Offers for ChangeOffer purchase.
   */
  // const changeOfferPurchase = {}
  /**
   *  Required. The resource name of the customer to list Offers for.
   *  Format: accounts/{account_id}/customers/{customer_id}.
   */
  // const customer = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, returns at most 100 Offers. The maximum value is
   *  1000; the server will coerce values above 1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   */
  // const languageCode = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListPurchasableOffers() {
    // Construct request
    const request = {
      customer,
    };

    // Run request
    const iterable = await channelClient.listPurchasableOffersAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListPurchasableOffers();

listPurchasableOffersStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
createEntitlementPurchase google.cloud.channel.v1.ListPurchasableOffersRequest.CreateEntitlementPurchase

List Offers for CreateEntitlement purchase.

changeOfferPurchase google.cloud.channel.v1.ListPurchasableOffersRequest.ChangeOfferPurchase

List Offers for ChangeOffer purchase.

customer string

Required. The resource name of the customer to list Offers for. Format: accounts/{account_id}/customers/{customer_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 Offers. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing PurchasableOffer on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listPurchasableOffersAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listPurchasableSkusAsync(request, optionsopt) → {Object}

Equivalent to listPurchasableSkus, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
createEntitlementPurchase google.cloud.channel.v1.ListPurchasableSkusRequest.CreateEntitlementPurchase

List SKUs for CreateEntitlement purchase.

changeOfferPurchase google.cloud.channel.v1.ListPurchasableSkusRequest.ChangeOfferPurchase

List SKUs for ChangeOffer purchase with a new SKU.

customer string

Required. The resource name of the customer to list SKUs for. Format: accounts/{account_id}/customers/{customer_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 SKUs. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing PurchasableSku. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  List SKUs for CreateEntitlement purchase.
   */
  // const createEntitlementPurchase = {}
  /**
   *  List SKUs for ChangeOffer purchase with a new SKU.
   */
  // const changeOfferPurchase = {}
  /**
   *  Required. The resource name of the customer to list SKUs for.
   *  Format: accounts/{account_id}/customers/{customer_id}.
   */
  // const customer = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, returns at most 100 SKUs. The maximum value is
   *  1000; the server will coerce values above 1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   */
  // const languageCode = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListPurchasableSkus() {
    // Construct request
    const request = {
      customer,
    };

    // Run request
    const iterable = await channelClient.listPurchasableSkusAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListPurchasableSkus();

listPurchasableSkusStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
createEntitlementPurchase google.cloud.channel.v1.ListPurchasableSkusRequest.CreateEntitlementPurchase

List SKUs for CreateEntitlement purchase.

changeOfferPurchase google.cloud.channel.v1.ListPurchasableSkusRequest.ChangeOfferPurchase

List SKUs for ChangeOffer purchase with a new SKU.

customer string

Required. The resource name of the customer to list SKUs for. Format: accounts/{account_id}/customers/{customer_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 SKUs. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing PurchasableSku on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listPurchasableSkusAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listSkuGroupBillableSkusAsync(request, optionsopt) → {Object}

Equivalent to listSkuGroupBillableSkus, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. Resource name of the SKU group. Format: accounts/{account}/skuGroups/{sku_group}.

pageSize number <optional>

Optional. The maximum number of SKUs to return. The service may return fewer than this value. If unspecified, returns a maximum of 100000 SKUs. The maximum value is 100000; values above 100000 will be coerced to 100000.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListSkuGroupBillableSkus.next_page_token of the previous CloudChannelService.ListSkuGroupBillableSkus call.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing BillableSku. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. Resource name of the SKU group.
   *  Format: accounts/{account}/skuGroups/{sku_group}.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of SKUs to return. The service may return
   *  fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
   *  The maximum value is 100000; values above 100000 will be coerced to 100000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token identifying a page of results beyond the first page.
   *  Obtained through
   *  ListSkuGroupBillableSkus.next_page_token   of the previous
   *  CloudChannelService.ListSkuGroupBillableSkus google.cloud.channel.v1.CloudChannelService.ListSkuGroupBillableSkus 
   *  call.
   */
  // const pageToken = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListSkuGroupBillableSkus() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listSkuGroupBillableSkusAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListSkuGroupBillableSkus();

listSkuGroupBillableSkusStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. Resource name of the SKU group. Format: accounts/{account}/skuGroups/{sku_group}.

pageSize number <optional>

Optional. The maximum number of SKUs to return. The service may return fewer than this value. If unspecified, returns a maximum of 100000 SKUs. The maximum value is 100000; values above 100000 will be coerced to 100000.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListSkuGroupBillableSkus.next_page_token of the previous CloudChannelService.ListSkuGroupBillableSkus call.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing BillableSku on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listSkuGroupBillableSkusAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listSkuGroupsAsync(request, optionsopt) → {Object}

Equivalent to listSkuGroups, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the account from which to list SKU groups. Parent uses the format: accounts/{account}.

pageSize number <optional>

Optional. The maximum number of SKU groups to return. The service may return fewer than this value. If unspecified, returns a maximum of 1000 SKU groups. The maximum value is 1000; values above 1000 will be coerced to 1000.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListSkuGroups.next_page_token of the previous CloudChannelService.ListSkuGroups call.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing SkuGroup. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the account from which to list SKU groups.
   *  Parent uses the format: accounts/{account}.
   */
  // const parent = 'abc123'
  /**
   *  Optional. The maximum number of SKU groups to return. The service may
   *  return fewer than this value. If unspecified, returns a maximum of 1000 SKU
   *  groups. The maximum value is 1000; values above 1000 will be coerced to
   *  1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token identifying a page of results beyond the first page.
   *  Obtained through
   *  ListSkuGroups.next_page_token   of the previous
   *  CloudChannelService.ListSkuGroups google.cloud.channel.v1.CloudChannelService.ListSkuGroups 
   *  call.
   */
  // const pageToken = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListSkuGroups() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listSkuGroupsAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListSkuGroups();

listSkuGroupsStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the account from which to list SKU groups. Parent uses the format: accounts/{account}.

pageSize number <optional>

Optional. The maximum number of SKU groups to return. The service may return fewer than this value. If unspecified, returns a maximum of 1000 SKU groups. The maximum value is 1000; values above 1000 will be coerced to 1000.

pageToken string <optional>

Optional. A token identifying a page of results beyond the first page. Obtained through ListSkuGroups.next_page_token of the previous CloudChannelService.ListSkuGroups call.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing SkuGroup on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listSkuGroupsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listSkusAsync(request, optionsopt) → {Object}

Equivalent to listSkus, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the Product to list SKUs for. Parent uses the format: products/{product_id}. Supports products/- to retrieve SKUs for all products.

account string

Required. Resource name of the reseller. Format: accounts/{account_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 SKUs. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page. Optional.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing Sku. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. The resource name of the Product to list SKUs for.
   *  Parent uses the format: products/{product_id}.
   *  Supports products/- to retrieve SKUs for all products.
   */
  // const parent = 'abc123'
  /**
   *  Required. Resource name of the reseller.
   *  Format: accounts/{account_id}.
   */
  // const account = 'abc123'
  /**
   *  Optional. Requested page size. Server might return fewer results than
   *  requested. If unspecified, returns at most 100 SKUs. The maximum value is
   *  1000; the server will coerce values above 1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A token for a page of results other than the first page.
   *  Optional.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   */
  // const languageCode = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListSkus() {
    // Construct request
    const request = {
      parent,
      account,
    };

    // Run request
    const iterable = await channelClient.listSkusAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListSkus();

listSkusStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
parent string

Required. The resource name of the Product to list SKUs for. Parent uses the format: products/{product_id}. Supports products/- to retrieve SKUs for all products.

account string

Required. Resource name of the reseller. Format: accounts/{account_id}.

pageSize number <optional>

Optional. Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 SKUs. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A token for a page of results other than the first page. Optional.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing Sku on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listSkusAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listSubscribersAsync(request, optionsopt) → {Object}

Equivalent to listSubscribers, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
account string

Required. Resource name of the account.

pageSize number <optional>

Optional. The maximum number of service accounts to return. The service may return fewer than this value. If unspecified, returns at most 100 service accounts. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A page token, received from a previous ListSubscribers call. Provide this to retrieve the subsequent page.

When paginating, all other parameters provided to ListSubscribers must match the call that provided the page token.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing string. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Required. Resource name of the account.
   */
  // const account = 'abc123'
  /**
   *  Optional. The maximum number of service accounts to return. The service may
   *  return fewer than this value. If unspecified, returns at most 100 service
   *  accounts. The maximum value is 1000; the server will coerce values above
   *  1000.
   */
  // const pageSize = 1234
  /**
   *  Optional. A page token, received from a previous `ListSubscribers` call.
   *  Provide this to retrieve the subsequent page.
   *  When paginating, all other parameters provided to `ListSubscribers` must
   *  match the call that provided the page token.
   */
  // const pageToken = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListSubscribers() {
    // Construct request
    const request = {
      account,
    };

    // Run request
    const iterable = await channelClient.listSubscribersAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListSubscribers();

listSubscribersStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
account string

Required. Resource name of the account.

pageSize number <optional>

Optional. The maximum number of service accounts to return. The service may return fewer than this value. If unspecified, returns at most 100 service accounts. The maximum value is 1000; the server will coerce values above 1000.

pageToken string <optional>

Optional. A page token, received from a previous ListSubscribers call. Provide this to retrieve the subsequent page.

When paginating, all other parameters provided to ListSubscribers must match the call that provided the page token.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing string on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listSubscribersAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listTransferableOffersAsync(request, optionsopt) → {Object}

Equivalent to listTransferableOffers, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
cloudIdentityId string

Customer's Cloud Identity ID

customerName string

A reseller should create a customer and use the resource name of that customer here.

parent string

Required. The resource name of the reseller's account.

pageSize number

Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 offers. The maximum value is 1000; the server will coerce values above 1000.

pageToken string

A token for a page of results other than the first page. Obtained using ListTransferableOffersResponse.next_page_token of the previous CloudChannelService.ListTransferableOffers call.

sku string

Required. The SKU to look up Offers for.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

billingAccount string <optional>

Optional. The Billing Account to look up Offers for. Format: accounts/{account_id}/billingAccounts/{billing_account_id}.

This field is only relevant for multi-currency accounts. It should be left empty for single currency accounts.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing TransferableOffer. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Customer's Cloud Identity ID
   */
  // const cloudIdentityId = 'abc123'
  /**
   *  A reseller should create a customer and use the resource name of
   *  that customer here.
   */
  // const customerName = 'abc123'
  /**
   *  Required. The resource name of the reseller's account.
   */
  // const parent = 'abc123'
  /**
   *  Requested page size. Server might return fewer results than requested.
   *  If unspecified, returns at most 100 offers.
   *  The maximum value is 1000; the server will coerce values above 1000.
   */
  // const pageSize = 1234
  /**
   *  A token for a page of results other than the first page.
   *  Obtained using
   *  ListTransferableOffersResponse.next_page_token google.cloud.channel.v1.ListTransferableOffersResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListTransferableOffers google.cloud.channel.v1.CloudChannelService.ListTransferableOffers 
   *  call.
   */
  // const pageToken = 'abc123'
  /**
   *  Required. The SKU to look up Offers for.
   */
  // const sku = 'abc123'
  /**
   *  Optional. The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   */
  // const languageCode = 'abc123'
  /**
   *  Optional. The Billing Account to look up Offers for. Format:
   *  accounts/{account_id}/billingAccounts/{billing_account_id}.
   *  This field is only relevant for multi-currency accounts. It should be left
   *  empty for single currency accounts.
   */
  // const billingAccount = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListTransferableOffers() {
    // Construct request
    const request = {
      parent,
      sku,
    };

    // Run request
    const iterable = await channelClient.listTransferableOffersAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListTransferableOffers();

listTransferableOffersStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
cloudIdentityId string

Customer's Cloud Identity ID

customerName string

A reseller should create a customer and use the resource name of that customer here.

parent string

Required. The resource name of the reseller's account.

pageSize number

Requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 offers. The maximum value is 1000; the server will coerce values above 1000.

pageToken string

A token for a page of results other than the first page. Obtained using ListTransferableOffersResponse.next_page_token of the previous CloudChannelService.ListTransferableOffers call.

sku string

Required. The SKU to look up Offers for.

languageCode string <optional>

Optional. The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US".

billingAccount string <optional>

Optional. The Billing Account to look up Offers for. Format: accounts/{account_id}/billingAccounts/{billing_account_id}.

This field is only relevant for multi-currency accounts. It should be left empty for single currency accounts.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing TransferableOffer on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listTransferableOffersAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listTransferableSkusAsync(request, optionsopt) → {Object}

Equivalent to listTransferableSkus, but returns an iterable object.

for-await-of syntax is used with the iterable to get response elements on-demand.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
cloudIdentityId string

Customer's Cloud Identity ID

customerName string

A reseller is required to create a customer and use the resource name of the created customer here. Customer_name uses the format: accounts/{account_id}/customers/{customer_id}

parent string

Required. The reseller account's resource name. Parent uses the format: accounts/{account_id}

pageSize number

The requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 SKUs. The maximum value is 1000; the server will coerce values above 1000. Optional.

pageToken string

A token for a page of results other than the first page. Obtained using ListTransferableSkusResponse.next_page_token of the previous CloudChannelService.ListTransferableSkus call. Optional.

authToken string <optional>

Optional. The super admin of the resold customer generates this token to authorize a reseller to access their Cloud Identity and purchase entitlements on their behalf. You can omit this token after authorization. See https://support.google.com/a/answer/7643790 for more details.

languageCode string

The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US". Optional.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Object

An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing TransferableSku. The API will be called under the hood as needed, once per the page, so you can stop the iteration when you don't need more results. Please see the documentation for more details and examples.

Example
  /**
   * This snippet has been automatically generated and should be regarded as a code template only.
   * It will require modifications to work.
   * It may require correct/in-range values for request initialization.
   * TODO(developer): Uncomment these variables before running the sample.
   */
  /**
   *  Customer's Cloud Identity ID
   */
  // const cloudIdentityId = 'abc123'
  /**
   *  A reseller is required to create a customer and use the resource name of
   *  the created customer here.
   *  Customer_name uses the format:
   *  accounts/{account_id}/customers/{customer_id}
   */
  // const customerName = 'abc123'
  /**
   *  Required. The reseller account's resource name.
   *  Parent uses the format: accounts/{account_id}
   */
  // const parent = 'abc123'
  /**
   *  The requested page size. Server might return fewer results than requested.
   *  If unspecified, returns at most 100 SKUs.
   *  The maximum value is 1000; the server will coerce values above 1000.
   *  Optional.
   */
  // const pageSize = 1234
  /**
   *  A token for a page of results other than the first page.
   *  Obtained using
   *  ListTransferableSkusResponse.next_page_token google.cloud.channel.v1.ListTransferableSkusResponse.next_page_token 
   *  of the previous
   *  CloudChannelService.ListTransferableSkus google.cloud.channel.v1.CloudChannelService.ListTransferableSkus 
   *  call. Optional.
   */
  // const pageToken = 'abc123'
  /**
   *  Optional. The super admin of the resold customer generates this token to
   *  authorize a reseller to access their Cloud Identity and purchase
   *  entitlements on their behalf. You can omit this token after authorization.
   *  See https://support.google.com/a/answer/7643790 for more details.
   */
  // const authToken = 'abc123'
  /**
   *  The BCP-47 language code. For example, "en-US". The
   *  response will localize in the corresponding language code, if specified.
   *  The default value is "en-US".
   *  Optional.
   */
  // const languageCode = 'abc123'

  // Imports the Channel library
  const {CloudChannelServiceClient} = require('@google-cloud/channel').v1;

  // Instantiates a client
  const channelClient = new CloudChannelServiceClient();

  async function callListTransferableSkus() {
    // Construct request
    const request = {
      parent,
    };

    // Run request
    const iterable = await channelClient.listTransferableSkusAsync(request);
    for await (const response of iterable) {
        console.log(response);
    }
  }

  callListTransferableSkus();

listTransferableSkusStream(request, optionsopt) → {Stream}

Equivalent to method.name.toCamelCase(), but returns a NodeJS Stream object.

Parameters:
Name Type Attributes Description
request Object

The request object that will be sent.

Properties
Name Type Attributes Description
cloudIdentityId string

Customer's Cloud Identity ID

customerName string

A reseller is required to create a customer and use the resource name of the created customer here. Customer_name uses the format: accounts/{account_id}/customers/{customer_id}

parent string

Required. The reseller account's resource name. Parent uses the format: accounts/{account_id}

pageSize number

The requested page size. Server might return fewer results than requested. If unspecified, returns at most 100 SKUs. The maximum value is 1000; the server will coerce values above 1000. Optional.

pageToken string

A token for a page of results other than the first page. Obtained using ListTransferableSkusResponse.next_page_token of the previous CloudChannelService.ListTransferableSkus call. Optional.

authToken string <optional>

Optional. The super admin of the resold customer generates this token to authorize a reseller to access their Cloud Identity and purchase entitlements on their behalf. You can omit this token after authorization. See https://support.google.com/a/answer/7643790 for more details.

languageCode string

The BCP-47 language code. For example, "en-US". The response will localize in the corresponding language code, if specified. The default value is "en-US". Optional.

options object <optional>

Call options. See CallOptions for more details.

Returns:
Type Description
Stream

An object stream which emits an object representing TransferableSku on 'data' event. The client library will perform auto-pagination by default: it will call the API as many times as needed. Note that it can affect your quota. We recommend using listTransferableSkusAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

matchAccountFromBillingAccountName(billingAccountName) → {string}

Parse the account from BillingAccount resource.

Parameters:
Name Type Description
billingAccountName string

A fully-qualified path representing BillingAccount resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromChannelPartnerLinkName(channelPartnerLinkName) → {string}

Parse the account from ChannelPartnerLink resource.

Parameters:
Name Type Description
channelPartnerLinkName string

A fully-qualified path representing ChannelPartnerLink resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromChannelPartnerRepricingConfigName(channelPartnerRepricingConfigName) → {string}

Parse the account from ChannelPartnerRepricingConfig resource.

Parameters:
Name Type Description
channelPartnerRepricingConfigName string

A fully-qualified path representing ChannelPartnerRepricingConfig resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromCustomerName(customerName) → {string}

Parse the account from Customer resource.

Parameters:
Name Type Description
customerName string

A fully-qualified path representing Customer resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromCustomerRepricingConfigName(customerRepricingConfigName) → {string}

Parse the account from CustomerRepricingConfig resource.

Parameters:
Name Type Description
customerRepricingConfigName string

A fully-qualified path representing CustomerRepricingConfig resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromEntitlementName(entitlementName) → {string}

Parse the account from Entitlement resource.

Parameters:
Name Type Description
entitlementName string

A fully-qualified path representing Entitlement resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromOfferName(offerName) → {string}

Parse the account from Offer resource.

Parameters:
Name Type Description
offerName string

A fully-qualified path representing Offer resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromReportJobName(reportJobName) → {string}

Parse the account from ReportJob resource.

Parameters:
Name Type Description
reportJobName string

A fully-qualified path representing ReportJob resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromReportName(reportName) → {string}

Parse the account from Report resource.

Parameters:
Name Type Description
reportName string

A fully-qualified path representing Report resource.

Returns:
Type Description
string

A string representing the account.

matchAccountFromSkuGroupName(skuGroupName) → {string}

Parse the account from SkuGroup resource.

Parameters:
Name Type Description
skuGroupName string

A fully-qualified path representing SkuGroup resource.

Returns:
Type Description
string

A string representing the account.

matchBillingAccountFromBillingAccountName(billingAccountName) → {string}

Parse the billing_account from BillingAccount resource.

Parameters:
Name Type Description
billingAccountName string

A fully-qualified path representing BillingAccount resource.

Returns:
Type Description
string

A string representing the billing_account.

matchChannelPartnerFromChannelPartnerRepricingConfigName(channelPartnerRepricingConfigName) → {string}

Parse the channel_partner from ChannelPartnerRepricingConfig resource.

Parameters:
Name Type Description
channelPartnerRepricingConfigName string

A fully-qualified path representing ChannelPartnerRepricingConfig resource.

Returns:
Type Description
string

A string representing the channel_partner.

matchChannelPartnerLinkFromChannelPartnerLinkName(channelPartnerLinkName) → {string}

Parse the channel_partner_link from ChannelPartnerLink resource.

Parameters:
Name Type Description
channelPartnerLinkName string

A fully-qualified path representing ChannelPartnerLink resource.

Returns:
Type Description
string

A string representing the channel_partner_link.

matchChannelPartnerRepricingConfigFromChannelPartnerRepricingConfigName(channelPartnerRepricingConfigName) → {string}

Parse the channel_partner_repricing_config from ChannelPartnerRepricingConfig resource.

Parameters:
Name Type Description
channelPartnerRepricingConfigName string

A fully-qualified path representing ChannelPartnerRepricingConfig resource.

Returns:
Type Description
string

A string representing the channel_partner_repricing_config.

matchCustomerFromCustomerName(customerName) → {string}

Parse the customer from Customer resource.

Parameters:
Name Type Description
customerName string

A fully-qualified path representing Customer resource.

Returns:
Type Description
string

A string representing the customer.

matchCustomerFromCustomerRepricingConfigName(customerRepricingConfigName) → {string}

Parse the customer from CustomerRepricingConfig resource.

Parameters:
Name Type Description
customerRepricingConfigName string

A fully-qualified path representing CustomerRepricingConfig resource.

Returns:
Type Description
string

A string representing the customer.

matchCustomerFromEntitlementName(entitlementName) → {string}

Parse the customer from Entitlement resource.

Parameters:
Name Type Description
entitlementName string

A fully-qualified path representing Entitlement resource.

Returns:
Type Description
string

A string representing the customer.

matchCustomerRepricingConfigFromCustomerRepricingConfigName(customerRepricingConfigName) → {string}

Parse the customer_repricing_config from CustomerRepricingConfig resource.

Parameters:
Name Type Description
customerRepricingConfigName string

A fully-qualified path representing CustomerRepricingConfig resource.

Returns:
Type Description
string

A string representing the customer_repricing_config.

matchEntitlementFromEntitlementName(entitlementName) → {string}

Parse the entitlement from Entitlement resource.

Parameters:
Name Type Description
entitlementName string

A fully-qualified path representing Entitlement resource.

Returns:
Type Description
string

A string representing the entitlement.

matchOfferFromOfferName(offerName) → {string}

Parse the offer from Offer resource.

Parameters:
Name Type Description
offerName string

A fully-qualified path representing Offer resource.

Returns:
Type Description
string

A string representing the offer.

matchProductFromProductName(productName) → {string}

Parse the product from Product resource.

Parameters:
Name Type Description
productName string

A fully-qualified path representing Product resource.

Returns:
Type Description
string

A string representing the product.

matchProductFromSkuName(skuName) → {string}

Parse the product from Sku resource.

Parameters:
Name Type Description
skuName string

A fully-qualified path representing Sku resource.

Returns:
Type Description
string

A string representing the product.

matchReportFromReportName(reportName) → {string}

Parse the report from Report resource.

Parameters:
Name Type Description
reportName string

A fully-qualified path representing Report resource.

Returns:
Type Description
string

A string representing the report.

matchReportJobFromReportJobName(reportJobName) → {string}

Parse the report_job from ReportJob resource.

Parameters:
Name Type Description
reportJobName string

A fully-qualified path representing ReportJob resource.

Returns:
Type Description
string

A string representing the report_job.

matchSkuFromSkuName(skuName) → {string}

Parse the sku from Sku resource.

Parameters:
Name Type Description
skuName string

A fully-qualified path representing Sku resource.

Returns:
Type Description
string

A string representing the sku.

matchSkuGroupFromSkuGroupName(skuGroupName) → {string}

Parse the sku_group from SkuGroup resource.

Parameters:
Name Type Description
skuGroupName string

A fully-qualified path representing SkuGroup resource.

Returns:
Type Description
string

A string representing the sku_group.

offerPath(account, offer) → {string}

Return a fully-qualified offer resource name string.

Parameters:
Name Type Description
account string
offer string
Returns:
Type Description
string

Resource name string.

productPath(product) → {string}

Return a fully-qualified product resource name string.

Parameters:
Name Type Description
product string
Returns:
Type Description
string

Resource name string.

reportJobPath(account, report_job) → {string}

Return a fully-qualified reportJob resource name string.

Parameters:
Name Type Description
account string
report_job string
Returns:
Type Description
string

Resource name string.

reportPath(account, report) → {string}

Return a fully-qualified report resource name string.

Parameters:
Name Type Description
account string
report string
Returns:
Type Description
string

Resource name string.

skuGroupPath(account, sku_group) → {string}

Return a fully-qualified skuGroup resource name string.

Parameters:
Name Type Description
account string
sku_group string
Returns:
Type Description
string

Resource name string.

skuPath(product, sku) → {string}

Return a fully-qualified sku resource name string.

Parameters:
Name Type Description
product string
sku string
Returns:
Type Description
string

Resource name string.