Class v1.LivestreamServiceClient (1.0.2)

Using Live Stream API, you can generate live streams in the various renditions and streaming formats. The streaming format include HTTP Live Streaming (HLS) and Dynamic Adaptive Streaming over HTTP (DASH). You can send a source stream in the various ways, including Real-Time Messaging Protocol (RTMP) and Secure Reliable Transport (SRT). v1

Package

@google-cloud/livestream

Constructors

(constructor)(opts, gaxInstance)

constructor(opts?: ClientOptions, gaxInstance?: typeof gax | typeof gax.fallback);

Construct an instance of LivestreamServiceClient.

Parameters
NameDescription
opts ClientOptions
gaxInstance typeof gax | typeof fallback

: 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 LivestreamServiceClient({fallback: true}, gax); ```

Properties

apiEndpoint

static get apiEndpoint(): string;

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

auth

auth: gax.GoogleAuth;

descriptors

descriptors: Descriptors;

innerApiCalls

innerApiCalls: {
        [name: string]: Function;
    };

livestreamServiceStub

livestreamServiceStub?: Promise<{
        [name: string]: Function;
    }>;

locationsClient

locationsClient: LocationsClient;

operationsClient

operationsClient: gax.OperationsClient;

pathTemplates

pathTemplates: {
        [name: string]: gax.PathTemplate;
    };

port

static get port(): number;

The port for this API service.

scopes

static get scopes(): string[];

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

servicePath

static get servicePath(): string;

The DNS address for this API service.

warn

warn: (code: string, message: string, warnType?: string) => void;

Methods

assetPath(project, location, asset)

assetPath(project: string, location: string, asset: string): string;

Return a fully-qualified asset resource name string.

Parameters
NameDescription
project string
location string
asset string
Returns
TypeDescription
string

{string} Resource name string.

cancelOperation(request, options, callback)

cancelOperation(request: protos.google.longrunning.CancelOperationRequest, options?: gax.CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.CancelOperationRequest, {} | undefined | null>, callback?: Callback<protos.google.longrunning.CancelOperationRequest, protos.google.protobuf.Empty, {} | undefined | null>): Promise<protos.google.protobuf.Empty>;

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 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 value with a of 1, corresponding to Code.CANCELLED.

Parameters
NameDescription
request CancelOperationRequest

The request object that will be sent.

options CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.CancelOperationRequest, {} | undefined | null>

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

callback Callback<protos.google.longrunning.CancelOperationRequest, protos.google.protobuf.Empty, {} | undefined | null>

The function which will be called with the result of the API call. {Promise} - The promise which resolves when API call finishes. The promise has a method named "cancel" which cancels the ongoing API call.

Returns
TypeDescription
Promise<protos.google.protobuf.Empty>
Example

const client = longrunning.operationsClient();
await client.cancelOperation({name: ''});

channelPath(project, location, channel)

channelPath(project: string, location: string, channel: string): string;

Return a fully-qualified channel resource name string.

Parameters
NameDescription
project string
location string
channel string
Returns
TypeDescription
string

{string} Resource name string.

checkCreateAssetProgress(name)

checkCreateAssetProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.Asset, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.Asset, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The asset resource to be created.
   */
  // const asset = {}
  /**
   *  Required. The ID of the asset resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const assetId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateAsset() {
    // Construct request
    const request = {
      parent,
      asset,
      assetId,
    };

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

  callCreateAsset();

checkCreateChannelProgress(name)

checkCreateChannelProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.Channel, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.Channel, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The channel resource to be created.
   */
  // const channel = {}
  /**
   *  Required. The ID of the channel resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const channelId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateChannel() {
    // Construct request
    const request = {
      parent,
      channel,
      channelId,
    };

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

  callCreateChannel();

checkCreateInputProgress(name)

checkCreateInputProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.Input, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.Input, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The input resource to be created.
   */
  // const input = {}
  /**
   *  Required. The ID of the input resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const inputId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateInput() {
    // Construct request
    const request = {
      parent,
      input,
      inputId,
    };

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

  callCreateInput();

checkDeleteAssetProgress(name)

checkDeleteAssetProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 asset resource, in the form of:
   *  `projects/{project}/locations/{location}/assets/{assetId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes after the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callDeleteAsset();

checkDeleteChannelProgress(name)

checkDeleteChannelProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes after the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'
  /**
   *  If the `force` field is set to the default value of `false`, you must
   *  delete all of a channel's events before you can delete the channel itself.
   *  If the field is set to `true`, requests to delete a channel also delete
   *  associated channel events.
   */
  // const force = true

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callDeleteChannel();

checkDeleteInputProgress(name)

checkDeleteInputProgress(name: string): Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.protobuf.Empty, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 input resource, in the form of:
   *  `projects/{project}/locations/{location}/inputs/{inputId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callDeleteInput();

checkStartChannelProgress(name)

checkStartChannelProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.ChannelOperationResponse, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.ChannelOperationResponse, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callStartChannel();

checkStopChannelProgress(name)

checkStopChannelProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.ChannelOperationResponse, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.ChannelOperationResponse, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callStopChannel();

checkUpdateChannelProgress(name)

checkUpdateChannelProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.Channel, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.Channel, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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.
   */
  /**
   *  Field mask is used to specify the fields to be overwritten in the Channel
   *  resource by the update. You can only update the following fields:
   *  * `inputAttachments` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#inputattachment)
   *  * `inputConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#inputconfig)
   *  * `output` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#output)
   *  * `elementaryStreams` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#elementarystream)
   *  * `muxStreams` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#muxstream)
   *  * `manifests` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#manifest)
   *  * `spriteSheets` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#spritesheet)
   *  * `logConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#logconfig)
   *  * `timecodeConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#timecodeconfig)
   *  * `encryptions` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#encryption)
   *  The fields specified in the update_mask are relative to the resource, not
   *  the full request. A field will be overwritten if it is in the mask.
   *  If the mask is not present, then each field from the list above is updated
   *  if the field appears in the request payload. To unset a field, add the
   *  field to the update mask and remove it from the request payload.
   */
  // const updateMask = {}
  /**
   *  Required. The channel resource to be updated.
   */
  // const channel = {}
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callUpdateChannel() {
    // Construct request
    const request = {
      channel,
    };

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

  callUpdateChannel();

checkUpdateInputProgress(name)

checkUpdateInputProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.Input, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.Input, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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.
   */
  /**
   *  Field mask is used to specify the fields to be overwritten in the Input
   *  resource by the update. You can only update the following fields:
   *  * `preprocessingConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs#PreprocessingConfig)
   *  * `securityRules` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs#SecurityRule)
   *  The fields specified in the update_mask are relative to the resource, not
   *  the full request. A field will be overwritten if it is in the mask.
   *  If the mask is not present, then each field from the list above is updated
   *  if the field appears in the request payload. To unset a field, add the
   *  field to the update mask and remove it from the request payload.
   */
  // const updateMask = {}
  /**
   *  Required. The input resource to be updated.
   */
  // const input = {}
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callUpdateInput() {
    // Construct request
    const request = {
      input,
    };

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

  callUpdateInput();

checkUpdatePoolProgress(name)

checkUpdatePoolProgress(name: string): Promise<LROperation<protos.google.cloud.video.livestream.v1.Pool, protos.google.cloud.video.livestream.v1.OperationMetadata>>;

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

Parameter
NameDescription
name string

The operation name that will be passed.

Returns
TypeDescription
Promise<LROperation<protos.google.cloud.video.livestream.v1.Pool, protos.google.cloud.video.livestream.v1.OperationMetadata>>

{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.
   */
  /**
   *  Field mask is used to specify the fields to be overwritten in the Pool
   *  resource by the update. You can only update the following fields:
   *  * `networkConfig`
   *  The fields specified in the update_mask are relative to the resource, not
   *  the full request. A field will be overwritten if it is in the mask.
   */
  // const updateMask = {}
  /**
   *  Required. The pool resource to be updated.
   */
  // const pool = {}
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callUpdatePool() {
    // Construct request
    const request = {
      pool,
    };

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

  callUpdatePool();

close()

close(): Promise<void>;

Terminate the gRPC channel and close the client.

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

Returns
TypeDescription
Promise<void>

{Promise} A promise that resolves when the client is closed.

createAsset(request, options)

createAsset(request?: protos.google.cloud.video.livestream.v1.ICreateAssetRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Creates a Asset with the provided unique ID in the specified region.

Parameters
NameDescription
request ICreateAssetRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The asset resource to be created.
   */
  // const asset = {}
  /**
   *  Required. The ID of the asset resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const assetId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateAsset() {
    // Construct request
    const request = {
      parent,
      asset,
      assetId,
    };

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

  callCreateAsset();

createAsset(request, options, callback)

createAsset(request: protos.google.cloud.video.livestream.v1.ICreateAssetRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateAssetRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createAsset(request, callback)

createAsset(request: protos.google.cloud.video.livestream.v1.ICreateAssetRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateAssetRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createChannel(request, options)

createChannel(request?: protos.google.cloud.video.livestream.v1.ICreateChannelRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Creates a channel with the provided unique ID in the specified region.

Parameters
NameDescription
request ICreateChannelRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The channel resource to be created.
   */
  // const channel = {}
  /**
   *  Required. The ID of the channel resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const channelId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateChannel() {
    // Construct request
    const request = {
      parent,
      channel,
      channelId,
    };

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

  callCreateChannel();

createChannel(request, options, callback)

createChannel(request: protos.google.cloud.video.livestream.v1.ICreateChannelRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateChannelRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createChannel(request, callback)

createChannel(request: protos.google.cloud.video.livestream.v1.ICreateChannelRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateChannelRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createEvent(request, options)

createEvent(request?: protos.google.cloud.video.livestream.v1.ICreateEventRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IEvent,
        protos.google.cloud.video.livestream.v1.ICreateEventRequest | undefined,
        {} | undefined
    ]>;

Creates an event with the provided unique ID in the specified channel.

Parameters
NameDescription
request ICreateEventRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.ICreateEventRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . 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 parent channel for the resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The event resource to be created.
   */
  // const event = {}
  /**
   *  Required. The ID of the event resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const eventId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateEvent() {
    // Construct request
    const request = {
      parent,
      event,
      eventId,
    };

    // Run request
    const response = await livestreamClient.createEvent(request);
    console.log(response);
  }

  callCreateEvent();

createEvent(request, options, callback)

createEvent(request: protos.google.cloud.video.livestream.v1.ICreateEventRequest, options: CallOptions, callback: Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.ICreateEventRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateEventRequest
options CallOptions
callback Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.ICreateEventRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createEvent(request, callback)

createEvent(request: protos.google.cloud.video.livestream.v1.ICreateEventRequest, callback: Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.ICreateEventRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateEventRequest
callback Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.ICreateEventRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createInput(request, options)

createInput(request?: protos.google.cloud.video.livestream.v1.ICreateInputRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Creates an input with the provided unique ID in the specified region.

Parameters
NameDescription
request ICreateInputRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Required. The input resource to be created.
   */
  // const input = {}
  /**
   *  Required. The ID of the input resource to be created.
   *  This value must be 1-63 characters, begin and end with `[a-z0-9]`,
   *  could contain dashes (-) in between.
   */
  // const inputId = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callCreateInput() {
    // Construct request
    const request = {
      parent,
      input,
      inputId,
    };

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

  callCreateInput();

createInput(request, options, callback)

createInput(request: protos.google.cloud.video.livestream.v1.ICreateInputRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateInputRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

createInput(request, callback)

createInput(request: protos.google.cloud.video.livestream.v1.ICreateInputRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request ICreateInputRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteAsset(request, options)

deleteAsset(request?: protos.google.cloud.video.livestream.v1.IDeleteAssetRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Deletes the specified asset if it is not used.

Parameters
NameDescription
request IDeleteAssetRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 asset resource, in the form of:
   *  `projects/{project}/locations/{location}/assets/{assetId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes after the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callDeleteAsset();

deleteAsset(request, options, callback)

deleteAsset(request: protos.google.cloud.video.livestream.v1.IDeleteAssetRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteAssetRequest
options CallOptions
callback Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteAsset(request, callback)

deleteAsset(request: protos.google.cloud.video.livestream.v1.IDeleteAssetRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteAssetRequest
callback Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteChannel(request, options)

deleteChannel(request?: protos.google.cloud.video.livestream.v1.IDeleteChannelRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Deletes the specified channel.

Parameters
NameDescription
request IDeleteChannelRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes after the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'
  /**
   *  If the `force` field is set to the default value of `false`, you must
   *  delete all of a channel's events before you can delete the channel itself.
   *  If the field is set to `true`, requests to delete a channel also delete
   *  associated channel events.
   */
  // const force = true

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callDeleteChannel();

deleteChannel(request, options, callback)

deleteChannel(request: protos.google.cloud.video.livestream.v1.IDeleteChannelRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteChannelRequest
options CallOptions
callback Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteChannel(request, callback)

deleteChannel(request: protos.google.cloud.video.livestream.v1.IDeleteChannelRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteChannelRequest
callback Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteEvent(request, options)

deleteEvent(request?: protos.google.cloud.video.livestream.v1.IDeleteEventRequest, options?: CallOptions): Promise<[
        protos.google.protobuf.IEmpty,
        protos.google.cloud.video.livestream.v1.IDeleteEventRequest | undefined,
        {} | undefined
    ]>;

Deletes the specified event.

Parameters
NameDescription
request IDeleteEventRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IDeleteEventRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing Empty. 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 event resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}/events/{eventId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

    // Run request
    const response = await livestreamClient.deleteEvent(request);
    console.log(response);
  }

  callDeleteEvent();

deleteEvent(request, options, callback)

deleteEvent(request: protos.google.cloud.video.livestream.v1.IDeleteEventRequest, options: CallOptions, callback: Callback<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IDeleteEventRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteEventRequest
options CallOptions
callback Callback<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IDeleteEventRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteEvent(request, callback)

deleteEvent(request: protos.google.cloud.video.livestream.v1.IDeleteEventRequest, callback: Callback<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IDeleteEventRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteEventRequest
callback Callback<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IDeleteEventRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteInput(request, options)

deleteInput(request?: protos.google.cloud.video.livestream.v1.IDeleteInputRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Deletes the specified input.

Parameters
NameDescription
request IDeleteInputRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 input resource, in the form of:
   *  `projects/{project}/locations/{location}/inputs/{inputId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callDeleteInput();

deleteInput(request, options, callback)

deleteInput(request: protos.google.cloud.video.livestream.v1.IDeleteInputRequest, options: CallOptions, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteInputRequest
options CallOptions
callback Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteInput(request, callback)

deleteInput(request: protos.google.cloud.video.livestream.v1.IDeleteInputRequest, callback: Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IDeleteInputRequest
callback Callback<LROperation<protos.google.protobuf.IEmpty, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

deleteOperation(request, options, callback)

deleteOperation(request: protos.google.longrunning.DeleteOperationRequest, options?: gax.CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>, callback?: Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>): Promise<protos.google.protobuf.Empty>;

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
NameDescription
request DeleteOperationRequest

The request object that will be sent.

options CallOptions | Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>

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

callback Callback<protos.google.protobuf.Empty, protos.google.longrunning.DeleteOperationRequest, {} | null | undefined>

The function which will be called with the result of the API call. {Promise} - The promise which resolves when API call finishes. The promise has a method named "cancel" which cancels the ongoing API call.

Returns
TypeDescription
Promise<protos.google.protobuf.Empty>
Example

const client = longrunning.operationsClient();
await client.deleteOperation({name: ''});

eventPath(project, location, channel, event)

eventPath(project: string, location: string, channel: string, event: string): string;

Return a fully-qualified event resource name string.

Parameters
NameDescription
project string
location string
channel string
event string
Returns
TypeDescription
string

{string} Resource name string.

getAsset(request, options)

getAsset(request?: protos.google.cloud.video.livestream.v1.IGetAssetRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IAsset,
        protos.google.cloud.video.livestream.v1.IGetAssetRequest | undefined,
        {} | undefined
    ]>;

Returns the specified asset.

Parameters
NameDescription
request IGetAssetRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IGetAssetRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . 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. Name of the resource, in the following form:
   *  `projects/{project}/locations/{location}/assets/{asset}`.
   */
  // const name = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

    // Run request
    const response = await livestreamClient.getAsset(request);
    console.log(response);
  }

  callGetAsset();

getAsset(request, options, callback)

getAsset(request: protos.google.cloud.video.livestream.v1.IGetAssetRequest, options: CallOptions, callback: Callback<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IGetAssetRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetAssetRequest
options CallOptions
callback Callback<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IGetAssetRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getAsset(request, callback)

getAsset(request: protos.google.cloud.video.livestream.v1.IGetAssetRequest, callback: Callback<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IGetAssetRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetAssetRequest
callback Callback<protos.google.cloud.video.livestream.v1.IAsset, protos.google.cloud.video.livestream.v1.IGetAssetRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getChannel(request, options)

getChannel(request?: protos.google.cloud.video.livestream.v1.IGetChannelRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IChannel,
        protos.google.cloud.video.livestream.v1.IGetChannelRequest | undefined,
        {} | undefined
    ]>;

Returns the specified channel.

Parameters
NameDescription
request IGetChannelRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IGetChannelRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . 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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

    // Run request
    const response = await livestreamClient.getChannel(request);
    console.log(response);
  }

  callGetChannel();

getChannel(request, options, callback)

getChannel(request: protos.google.cloud.video.livestream.v1.IGetChannelRequest, options: CallOptions, callback: Callback<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IGetChannelRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetChannelRequest
options CallOptions
callback Callback<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IGetChannelRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getChannel(request, callback)

getChannel(request: protos.google.cloud.video.livestream.v1.IGetChannelRequest, callback: Callback<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IGetChannelRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetChannelRequest
callback Callback<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IGetChannelRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getEvent(request, options)

getEvent(request?: protos.google.cloud.video.livestream.v1.IGetEventRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IEvent,
        protos.google.cloud.video.livestream.v1.IGetEventRequest | undefined,
        {} | undefined
    ]>;

Returns the specified event.

Parameters
NameDescription
request IGetEventRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.IGetEventRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . 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 event resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}/events/{eventId}`.
   */
  // const name = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

    // Run request
    const response = await livestreamClient.getEvent(request);
    console.log(response);
  }

  callGetEvent();

getEvent(request, options, callback)

getEvent(request: protos.google.cloud.video.livestream.v1.IGetEventRequest, options: CallOptions, callback: Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.IGetEventRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetEventRequest
options CallOptions
callback Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.IGetEventRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getEvent(request, callback)

getEvent(request: protos.google.cloud.video.livestream.v1.IGetEventRequest, callback: Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.IGetEventRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetEventRequest
callback Callback<protos.google.cloud.video.livestream.v1.IEvent, protos.google.cloud.video.livestream.v1.IGetEventRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getInput(request, options)

getInput(request?: protos.google.cloud.video.livestream.v1.IGetInputRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IInput,
        protos.google.cloud.video.livestream.v1.IGetInputRequest | undefined,
        {} | undefined
    ]>;

Returns the specified input.

Parameters
NameDescription
request IGetInputRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IGetInputRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . 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 input resource, in the form of:
   *  `projects/{project}/locations/{location}/inputs/{inputId}`.
   */
  // const name = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

    // Run request
    const response = await livestreamClient.getInput(request);
    console.log(response);
  }

  callGetInput();

getInput(request, options, callback)

getInput(request: protos.google.cloud.video.livestream.v1.IGetInputRequest, options: CallOptions, callback: Callback<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IGetInputRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetInputRequest
options CallOptions
callback Callback<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IGetInputRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getInput(request, callback)

getInput(request: protos.google.cloud.video.livestream.v1.IGetInputRequest, callback: Callback<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IGetInputRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetInputRequest
callback Callback<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IGetInputRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getLocation(request, options, callback)

getLocation(request: LocationProtos.google.cloud.location.IGetLocationRequest, options?: gax.CallOptions | Callback<LocationProtos.google.cloud.location.ILocation, LocationProtos.google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>, callback?: Callback<LocationProtos.google.cloud.location.ILocation, LocationProtos.google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>): Promise<LocationProtos.google.cloud.location.ILocation>;

Gets information about a location.

Parameters
NameDescription
request LocationProtos.google.cloud.location.IGetLocationRequest

The request object that will be sent.

options CallOptions | Callback<google.cloud.location.ILocation, google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>

Call options. See CallOptions for more details.

callback Callback<google.cloud.location.ILocation, google.cloud.location.IGetLocationRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
Promise<google.cloud.location.ILocation>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . Please see the documentation for more details and examples.

Example

const [response] = await client.getLocation(request);

getOperation(request, options, callback)

getOperation(request: protos.google.longrunning.GetOperationRequest, options?: gax.CallOptions | Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>, callback?: Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>): Promise<[protos.google.longrunning.Operation]>;

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
NameDescription
request GetOperationRequest

The request object that will be sent.

options CallOptions | Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>

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

callback Callback<protos.google.longrunning.Operation, protos.google.longrunning.GetOperationRequest, {} | null | undefined>

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

The second parameter to the callback is an object representing . {Promise} - The promise which resolves to an array. The first element of the array is an object representing . The promise has a method named "cancel" which cancels the ongoing API call.

Returns
TypeDescription
Promise<[protos.google.longrunning.Operation]>
Example

const client = longrunning.operationsClient();
const name = '';
const [response] = await client.getOperation({name});
// doThingsWith(response)

getPool(request, options)

getPool(request?: protos.google.cloud.video.livestream.v1.IGetPoolRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IPool,
        protos.google.cloud.video.livestream.v1.IGetPoolRequest | undefined,
        {} | undefined
    ]>;

Returns the specified pool.

Parameters
NameDescription
request IGetPoolRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IGetPoolRequest | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing . 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 pool resource, in the form of:
   *  `projects/{project}/locations/{location}/pools/{poolId}`.
   */
  // const name = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

    // Run request
    const response = await livestreamClient.getPool(request);
    console.log(response);
  }

  callGetPool();

getPool(request, options, callback)

getPool(request: protos.google.cloud.video.livestream.v1.IGetPoolRequest, options: CallOptions, callback: Callback<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IGetPoolRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetPoolRequest
options CallOptions
callback Callback<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IGetPoolRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getPool(request, callback)

getPool(request: protos.google.cloud.video.livestream.v1.IGetPoolRequest, callback: Callback<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IGetPoolRequest | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IGetPoolRequest
callback Callback<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IGetPoolRequest | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

getProjectId()

getProjectId(): Promise<string>;
Returns
TypeDescription
Promise<string>

getProjectId(callback)

getProjectId(callback: Callback<string, undefined, undefined>): void;
Parameter
NameDescription
callback Callback<string, undefined, undefined>
Returns
TypeDescription
void

initialize()

initialize(): Promise<{
        [name: string]: Function;
    }>;

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
TypeDescription
Promise<{ [name: string]: Function; }>

{Promise} A promise that resolves to an authenticated service stub.

inputPath(project, location, input)

inputPath(project: string, location: string, input: string): string;

Return a fully-qualified input resource name string.

Parameters
NameDescription
project string
location string
input string
Returns
TypeDescription
string

{string} Resource name string.

listAssets(request, options)

listAssets(request?: protos.google.cloud.video.livestream.v1.IListAssetsRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IAsset[],
        protos.google.cloud.video.livestream.v1.IListAssetsRequest | null,
        protos.google.cloud.video.livestream.v1.IListAssetsResponse
    ]>;

Returns a list of all assets in the specified region.

Parameters
NameDescription
request IListAssetsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IAsset[], protos.google.cloud.video.livestream.v1.IListAssetsRequest | null, protos.google.cloud.video.livestream.v1.IListAssetsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of . The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listAssetsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listAssets(request, options, callback)

listAssets(request: protos.google.cloud.video.livestream.v1.IListAssetsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListAssetsRequest, protos.google.cloud.video.livestream.v1.IListAssetsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IAsset>): void;
Parameters
NameDescription
request IListAssetsRequest
options CallOptions
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListAssetsRequest, protos.google.cloud.video.livestream.v1.IListAssetsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IAsset>
Returns
TypeDescription
void

listAssets(request, callback)

listAssets(request: protos.google.cloud.video.livestream.v1.IListAssetsRequest, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListAssetsRequest, protos.google.cloud.video.livestream.v1.IListAssetsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IAsset>): void;
Parameters
NameDescription
request IListAssetsRequest
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListAssetsRequest, protos.google.cloud.video.livestream.v1.IListAssetsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IAsset>
Returns
TypeDescription
void

listAssetsAsync(request, options)

listAssetsAsync(request?: protos.google.cloud.video.livestream.v1.IListAssetsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.video.livestream.v1.IAsset>;

Equivalent to listAssets, but returns an iterable object.

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

Parameters
NameDescription
request IListAssetsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
AsyncIterable<protos.google.cloud.video.livestream.v1.IAsset>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing . 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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  Requested page size. Server may return fewer items than requested.
   *  If unspecified, server will pick an appropriate default.
   */
  // const pageSize = 1234
  /**
   *  A token identifying a page of results the server should return.
   */
  // const pageToken = 'abc123'
  /**
   *  Filtering results
   */
  // const filter = 'abc123'
  /**
   *  Hint for how to order the results
   */
  // const orderBy = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callListAssets();

listAssetsStream(request, options)

listAssetsStream(request?: protos.google.cloud.video.livestream.v1.IListAssetsRequest, options?: CallOptions): Transform;

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

Parameters
NameDescription
request IListAssetsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Transform

{Stream} An object stream which emits an object representing 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 listAssetsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listChannels(request, options)

listChannels(request?: protos.google.cloud.video.livestream.v1.IListChannelsRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IChannel[],
        protos.google.cloud.video.livestream.v1.IListChannelsRequest | null,
        protos.google.cloud.video.livestream.v1.IListChannelsResponse
    ]>;

Returns a list of all channels in the specified region.

Parameters
NameDescription
request IListChannelsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IChannel[], protos.google.cloud.video.livestream.v1.IListChannelsRequest | null, protos.google.cloud.video.livestream.v1.IListChannelsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of . The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listChannelsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listChannels(request, options, callback)

listChannels(request: protos.google.cloud.video.livestream.v1.IListChannelsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListChannelsRequest, protos.google.cloud.video.livestream.v1.IListChannelsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IChannel>): void;
Parameters
NameDescription
request IListChannelsRequest
options CallOptions
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListChannelsRequest, protos.google.cloud.video.livestream.v1.IListChannelsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IChannel>
Returns
TypeDescription
void

listChannels(request, callback)

listChannels(request: protos.google.cloud.video.livestream.v1.IListChannelsRequest, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListChannelsRequest, protos.google.cloud.video.livestream.v1.IListChannelsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IChannel>): void;
Parameters
NameDescription
request IListChannelsRequest
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListChannelsRequest, protos.google.cloud.video.livestream.v1.IListChannelsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IChannel>
Returns
TypeDescription
void

listChannelsAsync(request, options)

listChannelsAsync(request?: protos.google.cloud.video.livestream.v1.IListChannelsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.video.livestream.v1.IChannel>;

Equivalent to listChannels, but returns an iterable object.

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

Parameters
NameDescription
request IListChannelsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
AsyncIterable<protos.google.cloud.video.livestream.v1.IChannel>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing . 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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  The maximum number of items to return. If unspecified, server
   *  will pick an appropriate default. Server may return fewer items than
   *  requested. A caller should only rely on response's
   *  next_page_token google.cloud.video.livestream.v1.ListChannelsResponse.next_page_token 
   *  to determine if there are more items left to be queried.
   */
  // const pageSize = 1234
  /**
   *  The next_page_token value returned from a previous List request, if any.
   */
  // const pageToken = 'abc123'
  /**
   *  The filter to apply to list results.
   */
  // const filter = 'abc123'
  /**
   *  Specifies the ordering of results following syntax at
   *  https://cloud.google.com/apis/design/design_patterns#sorting_order.
   */
  // const orderBy = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callListChannels();

listChannelsStream(request, options)

listChannelsStream(request?: protos.google.cloud.video.livestream.v1.IListChannelsRequest, options?: CallOptions): Transform;

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

Parameters
NameDescription
request IListChannelsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Transform

{Stream} An object stream which emits an object representing 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 listChannelsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listEvents(request, options)

listEvents(request?: protos.google.cloud.video.livestream.v1.IListEventsRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IEvent[],
        protos.google.cloud.video.livestream.v1.IListEventsRequest | null,
        protos.google.cloud.video.livestream.v1.IListEventsResponse
    ]>;

Returns a list of all events in the specified channel.

Parameters
NameDescription
request IListEventsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IEvent[], protos.google.cloud.video.livestream.v1.IListEventsRequest | null, protos.google.cloud.video.livestream.v1.IListEventsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of . The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listEventsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listEvents(request, options, callback)

listEvents(request: protos.google.cloud.video.livestream.v1.IListEventsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListEventsRequest, protos.google.cloud.video.livestream.v1.IListEventsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IEvent>): void;
Parameters
NameDescription
request IListEventsRequest
options CallOptions
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListEventsRequest, protos.google.cloud.video.livestream.v1.IListEventsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IEvent>
Returns
TypeDescription
void

listEvents(request, callback)

listEvents(request: protos.google.cloud.video.livestream.v1.IListEventsRequest, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListEventsRequest, protos.google.cloud.video.livestream.v1.IListEventsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IEvent>): void;
Parameters
NameDescription
request IListEventsRequest
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListEventsRequest, protos.google.cloud.video.livestream.v1.IListEventsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IEvent>
Returns
TypeDescription
void

listEventsAsync(request, options)

listEventsAsync(request?: protos.google.cloud.video.livestream.v1.IListEventsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.video.livestream.v1.IEvent>;

Equivalent to listEvents, but returns an iterable object.

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

Parameters
NameDescription
request IListEventsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
AsyncIterable<protos.google.cloud.video.livestream.v1.IEvent>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing . 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 parent channel for the resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const parent = 'abc123'
  /**
   *  The maximum number of items to return. If unspecified, server
   *  will pick an appropriate default. Server may return fewer items than
   *  requested. A caller should only rely on response's
   *  next_page_token google.cloud.video.livestream.v1.ListEventsResponse.next_page_token 
   *  to determine if there are more items left to be queried.
   */
  // const pageSize = 1234
  /**
   *  The next_page_token value returned from a previous List request, if any.
   */
  // const pageToken = 'abc123'
  /**
   *  The filter to apply to list results.
   */
  // const filter = 'abc123'
  /**
   *  Specifies the ordering of results following syntax at
   *  https://cloud.google.com/apis/design/design_patterns#sorting_order.
   */
  // const orderBy = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callListEvents();

listEventsStream(request, options)

listEventsStream(request?: protos.google.cloud.video.livestream.v1.IListEventsRequest, options?: CallOptions): Transform;

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

Parameters
NameDescription
request IListEventsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Transform

{Stream} An object stream which emits an object representing 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 listEventsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listInputs(request, options)

listInputs(request?: protos.google.cloud.video.livestream.v1.IListInputsRequest, options?: CallOptions): Promise<[
        protos.google.cloud.video.livestream.v1.IInput[],
        protos.google.cloud.video.livestream.v1.IListInputsRequest | null,
        protos.google.cloud.video.livestream.v1.IListInputsResponse
    ]>;

Returns a list of all inputs in the specified region.

Parameters
NameDescription
request IListInputsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ protos.google.cloud.video.livestream.v1.IInput[], protos.google.cloud.video.livestream.v1.IListInputsRequest | null, protos.google.cloud.video.livestream.v1.IListInputsResponse ]>

{Promise} - The promise which resolves to an array. The first element of the array is Array of . The client library will perform auto-pagination by default: it will call the API as many times as needed and will merge results from all the pages into this array. Note that it can affect your quota. We recommend using listInputsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listInputs(request, options, callback)

listInputs(request: protos.google.cloud.video.livestream.v1.IListInputsRequest, options: CallOptions, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListInputsRequest, protos.google.cloud.video.livestream.v1.IListInputsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IInput>): void;
Parameters
NameDescription
request IListInputsRequest
options CallOptions
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListInputsRequest, protos.google.cloud.video.livestream.v1.IListInputsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IInput>
Returns
TypeDescription
void

listInputs(request, callback)

listInputs(request: protos.google.cloud.video.livestream.v1.IListInputsRequest, callback: PaginationCallback<protos.google.cloud.video.livestream.v1.IListInputsRequest, protos.google.cloud.video.livestream.v1.IListInputsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IInput>): void;
Parameters
NameDescription
request IListInputsRequest
callback PaginationCallback<protos.google.cloud.video.livestream.v1.IListInputsRequest, protos.google.cloud.video.livestream.v1.IListInputsResponse | null | undefined, protos.google.cloud.video.livestream.v1.IInput>
Returns
TypeDescription
void

listInputsAsync(request, options)

listInputsAsync(request?: protos.google.cloud.video.livestream.v1.IListInputsRequest, options?: CallOptions): AsyncIterable<protos.google.cloud.video.livestream.v1.IInput>;

Equivalent to listInputs, but returns an iterable object.

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

Parameters
NameDescription
request IListInputsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
AsyncIterable<protos.google.cloud.video.livestream.v1.IInput>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing . 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 parent location for the resource, in the form of:
   *  `projects/{project}/locations/{location}`.
   */
  // const parent = 'abc123'
  /**
   *  The maximum number of items to return. If unspecified, server
   *  will pick an appropriate default. Server may return fewer items than
   *  requested. A caller should only rely on response's
   *  next_page_token google.cloud.video.livestream.v1.ListInputsResponse.next_page_token 
   *  to determine if there are more items left to be queried.
   */
  // const pageSize = 1234
  /**
   *  The next_page_token value returned from a previous List request, if any.
   */
  // const pageToken = 'abc123'
  /**
   *  The filter to apply to list results.
   */
  // const filter = 'abc123'
  /**
   *  Specifies the ordering of results following syntax at Sorting
   *  Order (https://cloud.google.com/apis/design/design_patterns#sorting_order).
   */
  // const orderBy = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callListInputs();

listInputsStream(request, options)

listInputsStream(request?: protos.google.cloud.video.livestream.v1.IListInputsRequest, options?: CallOptions): Transform;

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

Parameters
NameDescription
request IListInputsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Transform

{Stream} An object stream which emits an object representing 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 listInputsAsync() method described below for async iteration which you can stop as needed. Please see the documentation for more details and examples.

listLocationsAsync(request, options)

listLocationsAsync(request: LocationProtos.google.cloud.location.IListLocationsRequest, options?: CallOptions): AsyncIterable<LocationProtos.google.cloud.location.ILocation>;

Lists information about the supported locations for this service. Returns an iterable object.

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

Parameters
NameDescription
request LocationProtos.google.cloud.location.IListLocationsRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
AsyncIterable<google.cloud.location.ILocation>

{Object} An iterable Object that allows async iteration. When you iterate the returned iterable, each element will be an object representing . 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

const iterable = client.listLocationsAsync(request);
for await (const response of iterable) {
  // process response
}

listOperationsAsync(request, options)

listOperationsAsync(request: protos.google.longrunning.ListOperationsRequest, options?: gax.CallOptions): AsyncIterable<protos.google.longrunning.ListOperationsResponse>;

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
NameDescription
request ListOperationsRequest

The request object that will be sent.

options CallOptions

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

Returns
TypeDescription
AsyncIterable<protos.google.longrunning.ListOperationsResponse>

{Object} An iterable Object that conforms to iteration protocols.

Example

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

locationPath(project, location)

locationPath(project: string, location: string): string;

Return a fully-qualified location resource name string.

Parameters
NameDescription
project string
location string
Returns
TypeDescription
string

{string} Resource name string.

matchAssetFromAssetName(assetName)

matchAssetFromAssetName(assetName: string): string | number;

Parse the asset from Asset resource.

Parameter
NameDescription
assetName string

A fully-qualified path representing Asset resource.

Returns
TypeDescription
string | number

{string} A string representing the asset.

matchChannelFromChannelName(channelName)

matchChannelFromChannelName(channelName: string): string | number;

Parse the channel from Channel resource.

Parameter
NameDescription
channelName string

A fully-qualified path representing Channel resource.

Returns
TypeDescription
string | number

{string} A string representing the channel.

matchChannelFromEventName(eventName)

matchChannelFromEventName(eventName: string): string | number;

Parse the channel from Event resource.

Parameter
NameDescription
eventName string

A fully-qualified path representing Event resource.

Returns
TypeDescription
string | number

{string} A string representing the channel.

matchEventFromEventName(eventName)

matchEventFromEventName(eventName: string): string | number;

Parse the event from Event resource.

Parameter
NameDescription
eventName string

A fully-qualified path representing Event resource.

Returns
TypeDescription
string | number

{string} A string representing the event.

matchInputFromInputName(inputName)

matchInputFromInputName(inputName: string): string | number;

Parse the input from Input resource.

Parameter
NameDescription
inputName string

A fully-qualified path representing Input resource.

Returns
TypeDescription
string | number

{string} A string representing the input.

matchLocationFromAssetName(assetName)

matchLocationFromAssetName(assetName: string): string | number;

Parse the location from Asset resource.

Parameter
NameDescription
assetName string

A fully-qualified path representing Asset resource.

Returns
TypeDescription
string | number

{string} A string representing the location.

matchLocationFromChannelName(channelName)

matchLocationFromChannelName(channelName: string): string | number;

Parse the location from Channel resource.

Parameter
NameDescription
channelName string

A fully-qualified path representing Channel resource.

Returns
TypeDescription
string | number

{string} A string representing the location.

matchLocationFromEventName(eventName)

matchLocationFromEventName(eventName: string): string | number;

Parse the location from Event resource.

Parameter
NameDescription
eventName string

A fully-qualified path representing Event resource.

Returns
TypeDescription
string | number

{string} A string representing the location.

matchLocationFromInputName(inputName)

matchLocationFromInputName(inputName: string): string | number;

Parse the location from Input resource.

Parameter
NameDescription
inputName string

A fully-qualified path representing Input resource.

Returns
TypeDescription
string | number

{string} A string representing the location.

matchLocationFromLocationName(locationName)

matchLocationFromLocationName(locationName: string): string | number;

Parse the location from Location resource.

Parameter
NameDescription
locationName string

A fully-qualified path representing Location resource.

Returns
TypeDescription
string | number

{string} A string representing the location.

matchLocationFromPoolName(poolName)

matchLocationFromPoolName(poolName: string): string | number;

Parse the location from Pool resource.

Parameter
NameDescription
poolName string

A fully-qualified path representing Pool resource.

Returns
TypeDescription
string | number

{string} A string representing the location.

matchPoolFromPoolName(poolName)

matchPoolFromPoolName(poolName: string): string | number;

Parse the pool from Pool resource.

Parameter
NameDescription
poolName string

A fully-qualified path representing Pool resource.

Returns
TypeDescription
string | number

{string} A string representing the pool.

matchProjectFromAssetName(assetName)

matchProjectFromAssetName(assetName: string): string | number;

Parse the project from Asset resource.

Parameter
NameDescription
assetName string

A fully-qualified path representing Asset resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

matchProjectFromChannelName(channelName)

matchProjectFromChannelName(channelName: string): string | number;

Parse the project from Channel resource.

Parameter
NameDescription
channelName string

A fully-qualified path representing Channel resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

matchProjectFromEventName(eventName)

matchProjectFromEventName(eventName: string): string | number;

Parse the project from Event resource.

Parameter
NameDescription
eventName string

A fully-qualified path representing Event resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

matchProjectFromInputName(inputName)

matchProjectFromInputName(inputName: string): string | number;

Parse the project from Input resource.

Parameter
NameDescription
inputName string

A fully-qualified path representing Input resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

matchProjectFromLocationName(locationName)

matchProjectFromLocationName(locationName: string): string | number;

Parse the project from Location resource.

Parameter
NameDescription
locationName string

A fully-qualified path representing Location resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

matchProjectFromPoolName(poolName)

matchProjectFromPoolName(poolName: string): string | number;

Parse the project from Pool resource.

Parameter
NameDescription
poolName string

A fully-qualified path representing Pool resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

matchProjectFromProjectName(projectName)

matchProjectFromProjectName(projectName: string): string | number;

Parse the project from Project resource.

Parameter
NameDescription
projectName string

A fully-qualified path representing Project resource.

Returns
TypeDescription
string | number

{string} A string representing the project.

poolPath(project, location, pool)

poolPath(project: string, location: string, pool: string): string;

Return a fully-qualified pool resource name string.

Parameters
NameDescription
project string
location string
pool string
Returns
TypeDescription
string

{string} Resource name string.

projectPath(project)

projectPath(project: string): string;

Return a fully-qualified project resource name string.

Parameter
NameDescription
project string
Returns
TypeDescription
string

{string} Resource name string.

startChannel(request, options)

startChannel(request?: protos.google.cloud.video.livestream.v1.IStartChannelRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Starts the specified channel. Part of the video pipeline will be created only when the StartChannel request is received by the server.

Parameters
NameDescription
request IStartChannelRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callStartChannel();

startChannel(request, options, callback)

startChannel(request: protos.google.cloud.video.livestream.v1.IStartChannelRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IStartChannelRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

startChannel(request, callback)

startChannel(request: protos.google.cloud.video.livestream.v1.IStartChannelRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IStartChannelRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

stopChannel(request, options)

stopChannel(request?: protos.google.cloud.video.livestream.v1.IStopChannelRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Stops the specified channel. Part of the video pipeline will be released when the StopChannel request is received by the server.

Parameters
NameDescription
request IStopChannelRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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 channel resource, in the form of:
   *  `projects/{project}/locations/{location}/channels/{channelId}`.
   */
  // const name = 'abc123'
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

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

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

  callStopChannel();

stopChannel(request, options, callback)

stopChannel(request: protos.google.cloud.video.livestream.v1.IStopChannelRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IStopChannelRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

stopChannel(request, callback)

stopChannel(request: protos.google.cloud.video.livestream.v1.IStopChannelRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IStopChannelRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannelOperationResponse, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

updateChannel(request, options)

updateChannel(request?: protos.google.cloud.video.livestream.v1.IUpdateChannelRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates the specified channel.

Parameters
NameDescription
request IUpdateChannelRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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.
   */
  /**
   *  Field mask is used to specify the fields to be overwritten in the Channel
   *  resource by the update. You can only update the following fields:
   *  * `inputAttachments` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#inputattachment)
   *  * `inputConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#inputconfig)
   *  * `output` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#output)
   *  * `elementaryStreams` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#elementarystream)
   *  * `muxStreams` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#muxstream)
   *  * `manifests` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#manifest)
   *  * `spriteSheets` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#spritesheet)
   *  * `logConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#logconfig)
   *  * `timecodeConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#timecodeconfig)
   *  * `encryptions` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.channels#encryption)
   *  The fields specified in the update_mask are relative to the resource, not
   *  the full request. A field will be overwritten if it is in the mask.
   *  If the mask is not present, then each field from the list above is updated
   *  if the field appears in the request payload. To unset a field, add the
   *  field to the update mask and remove it from the request payload.
   */
  // const updateMask = {}
  /**
   *  Required. The channel resource to be updated.
   */
  // const channel = {}
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callUpdateChannel() {
    // Construct request
    const request = {
      channel,
    };

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

  callUpdateChannel();

updateChannel(request, options, callback)

updateChannel(request: protos.google.cloud.video.livestream.v1.IUpdateChannelRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IUpdateChannelRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

updateChannel(request, callback)

updateChannel(request: protos.google.cloud.video.livestream.v1.IUpdateChannelRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IUpdateChannelRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IChannel, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

updateInput(request, options)

updateInput(request?: protos.google.cloud.video.livestream.v1.IUpdateInputRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates the specified input.

Parameters
NameDescription
request IUpdateInputRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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.
   */
  /**
   *  Field mask is used to specify the fields to be overwritten in the Input
   *  resource by the update. You can only update the following fields:
   *  * `preprocessingConfig` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs#PreprocessingConfig)
   *  * `securityRules` (https://cloud.google.com/livestream/docs/reference/rest/v1/projects.locations.inputs#SecurityRule)
   *  The fields specified in the update_mask are relative to the resource, not
   *  the full request. A field will be overwritten if it is in the mask.
   *  If the mask is not present, then each field from the list above is updated
   *  if the field appears in the request payload. To unset a field, add the
   *  field to the update mask and remove it from the request payload.
   */
  // const updateMask = {}
  /**
   *  Required. The input resource to be updated.
   */
  // const input = {}
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callUpdateInput() {
    // Construct request
    const request = {
      input,
    };

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

  callUpdateInput();

updateInput(request, options, callback)

updateInput(request: protos.google.cloud.video.livestream.v1.IUpdateInputRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IUpdateInputRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

updateInput(request, callback)

updateInput(request: protos.google.cloud.video.livestream.v1.IUpdateInputRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IUpdateInputRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IInput, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

updatePool(request, options)

updatePool(request?: protos.google.cloud.video.livestream.v1.IUpdatePoolRequest, options?: CallOptions): Promise<[
        LROperation<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IOperationMetadata>,
        protos.google.longrunning.IOperation | undefined,
        {} | undefined
    ]>;

Updates the specified pool.

Parameters
NameDescription
request IUpdatePoolRequest

The request object that will be sent.

options CallOptions

Call options. See CallOptions for more details.

Returns
TypeDescription
Promise<[ LROperation<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | undefined, {} | undefined ]>

{Promise} - The promise which resolves to an array. The first element of the array is an object representing a long running operation. Its promise() method returns a promise you can await for. 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.
   */
  /**
   *  Field mask is used to specify the fields to be overwritten in the Pool
   *  resource by the update. You can only update the following fields:
   *  * `networkConfig`
   *  The fields specified in the update_mask are relative to the resource, not
   *  the full request. A field will be overwritten if it is in the mask.
   */
  // const updateMask = {}
  /**
   *  Required. The pool resource to be updated.
   */
  // const pool = {}
  /**
   *  A request ID to identify requests. Specify a unique request ID
   *  so that if you must retry your request, the server will know to ignore
   *  the request if it has already been completed. The server will guarantee
   *  that for at least 60 minutes since the first request.
   *  For example, consider a situation where 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 original operation with the same request ID was
   *  received, and if so, will ignore the second request. This prevents clients
   *  from accidentally creating duplicate commitments.
   *  The request ID must be a valid UUID with the exception that zero UUID is
   *  not supported `(00000000-0000-0000-0000-000000000000)`.
   */
  // const requestId = 'abc123'

  // Imports the Livestream library
  const {LivestreamServiceClient} = require('@google-cloud/livestream').v1;

  // Instantiates a client
  const livestreamClient = new LivestreamServiceClient();

  async function callUpdatePool() {
    // Construct request
    const request = {
      pool,
    };

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

  callUpdatePool();

updatePool(request, options, callback)

updatePool(request: protos.google.cloud.video.livestream.v1.IUpdatePoolRequest, options: CallOptions, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IUpdatePoolRequest
options CallOptions
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void

updatePool(request, callback)

updatePool(request: protos.google.cloud.video.livestream.v1.IUpdatePoolRequest, callback: Callback<LROperation<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>): void;
Parameters
NameDescription
request IUpdatePoolRequest
callback Callback<LROperation<protos.google.cloud.video.livestream.v1.IPool, protos.google.cloud.video.livestream.v1.IOperationMetadata>, protos.google.longrunning.IOperation | null | undefined, {} | null | undefined>
Returns
TypeDescription
void