Delete tenant (v4beta1)

Stay organized with collections Save and categorize content based on your preferences.

Delete tenant.

Explore further

For detailed documentation that includes this code sample, see the following:

Code sample


const talent = require('@google-cloud/talent').v4;

/** Delete Tenant */
function sampleDeleteTenant(projectId, tenantId) {
  const client = new talent.TenantServiceClient();
  // const projectId = 'Your Google Cloud Project ID';
  // const tenantId = 'Your Tenant ID)';
  const formattedName = client.tenantPath(projectId, tenantId);
  client.deleteTenant({name: formattedName}).catch(err => {
  console.log('Deleted Tenant.');


from import talent
import six

def delete_tenant(project_id, tenant_id):
    """Delete Tenant"""

    client = talent.TenantServiceClient()

    # project_id = 'Your Google Cloud Project ID'
    # tenant_id = 'Your Tenant ID)'

    if isinstance(project_id, six.binary_type):
        project_id = project_id.decode("utf-8")
    if isinstance(tenant_id, six.binary_type):
        tenant_id = tenant_id.decode("utf-8")
    name = client.tenant_path(project_id, tenant_id)

    print("Deleted Tenant.")

What's next

To search and filter code samples for other Google Cloud products, see the Google Cloud sample browser.