This article is written for Google Workspace administrators.

Introduction

In this article, you will learn about how to bulk archive users in Google Workspace. Archiving users is one of the most important administrative tasks in organizations. To archive users is exceptionally beneficial for HR or allied departments because when the employees leave the organization, their accounts are not of much use now. It is possible if the organization wants to preserve its user accounts' data or archive user licenses. It is also cheaper to archive user licenses than create an active user license in Google Workspace.

What is the requirement for archiving users?

The reason we require to archive users is because of the fact that when employees leave the organization, the organization does not want to remove their accounts immediately because the organization might want to preserve the data of their user accounts.

A Google Workspace Archive User (AU) license is different from the active users, and with this, you can now maintain the data more securely. Also, you can separate it from your current Workspace services.

Some of the notable advantages of archiving users in Google Workspace are –

  • Pocket-friendly: Compared to creating new user licenses, archiving them is more cost-effective.
  • Ease of management: You can easily archive a user from the Google Workspace console and, if needed, unarchive them.
  • Complete coverage over the information: With this archiving facility, you have complete control over the data.

With the advantages of archiving users out of the way, you should know about the process of bulk user archiving and how it is beneficial for you.

Why should we archive the users?

We need to archive users because when the employees leave the organization, the organization may or may not want to preserve their user accounts' data. It is better and cheaper for organizations to achieve user licenses than to spend an active user license in Google Workspace. Archiving is performed from time to time to clear the work area to make space for the new entries.

Why should we bulk archive users?

We need to bulk archive users because it's time-consuming archiving individual users one-by-one in Google Admin Console. Foresight helps us to automate several tasks at once by streamlining the workflow. You can learn more about Foresight by following the link provided here.

That is where Foresight comes into play. Foresight helps us to bulk archive users, which helps us to save time and increase productivity. You can also learn more about Foresight by going to the products page, link is given in the video description.

Use case objective - Bulk archive users in a CSV sheet

Now, to offer a demonstration of how Foresight works, we will be designing a workflow for you where we will bulk archive users and notify the archived users' managers. Notifying users' managers after the user has been archived is an important part of the employee off-boarding process. All stakeholders need to be alerted via email prior to the start of the off-boarding process and once it finishes. This way, you will have a clearer understanding of what is going on. 

Video Demo for Bulk archive users

This video demo shows a simple example case. Suppose you need to bulk archive a list of employees with the help of their user email addresses. You can automate the bulk archiving and sending a personalized email to the respective manager. 

Instructions

Preparation

Before setting up the Foresight rule, prepare a CSV file with only 1 column. Download Sample Archive User CSV File.

Email Address, the primary email addresses of users to be archived. 

Email Address
[email protected]
[email protected]
[email protected]
CSV template for bulk archiving Google Workspace users

Rule setup

Here are the steps to create the rule in Foresight to automate the use case above. 

  1. First of all, sign into Foresight or sign up for Foresight, if you don't have one.
  2. Go to the Rules page, and click the New Rule button.
  3. In the Select a trigger screen, select the Data uploaded trigger.
    Data uploaded trigger in xFanatical Foresight
  4. In the Edit trigger screen for the Data uploaded trigger, select the CSV file in the Preparation step above. You can also drag and drop the CSV file in the dashed rectangle area.Select Data Uploaded Trigger
  5. After the CSV file is parsed shortly, You will see the column definitions of the CSV file. For this use case, we only have 1 column. It maps the column to an EMAIL type variable. Fill in the required fields if any and then click NEXT.
  6. In the Select an action screen, select the Get user info Action. Get user info action in xFanatical Foresight
  7. In the Edit actions screen for the Get user info action, select the Email Address variable from the dropdown list In the Primary email field.Get User info action edit screen
  8. Click Add next action.
  9. In the Select an action screen, select the Archive user action.Select Archive user action
  10. In the Edit actions screen for the Archive user action, select the Email Address variable from the dropdown list in the Primary email field. This is a variable output from the Data uploaded trigger.Edit Archive user action
  11. In the Select an action screen, select the If action.Select an IF action
  12. In the Edit actions screen for the If action,Edit IF action
    • rename the Branch 1 branch to User has manager.
    • Set the condition for the User has manager branch to Manager email is not empty.
    • Click Add next action
    • rename the Branch 1 branch to User has manager.
    • Set the condition for the User has manager branch to Manager email is not empty.
    • Click Add next action
  13. In the Select an action screen, select the Email action.Select Email action
  14. In the Edit actions screen for the Email action, select the recipient in the To field. The To field is Manager's email address, which receives archived user detail, and add a Subject line.Add To field and add a subject line
  15. Compose an email template for the managers in the email body. To include the archived user's information for the manager select the variables from the dropdown list.Compose an email to Manageer
  16. Click Review
  17. In the Review screen, name the rule, and click create.Give a rule name and click create
  18. Your rule is created, shown as a card as follows.xFanatical Foresight rule graph for Google Workspace archive User

Rule test

  • Upload the csv file

On the newly created rule card, click the button and select the same CSV file from the Preparation step above.

Foresight starts processing your uploaded CSV file. Hover over the circular progress bar. You can see the data processing progress of the CSV file, including the number of data rows, columns, processed rows, ignored rows and remaining rows.

processing uploaded csv file
CSV Data processing status in xFanatical Foresight
  • Check rule notifications

Foresight notifies you of the processing results within the application , including the start of csv file processing, the result for each rule execution and the processing end summary. Foresight also sends you an email notification when the CSV data processing is complete.

Check rule notifications
New notifications in xFanatical Foresight
  • Check rule logs

In the Foresight Logs page, you can find each rule execution history. Each row in your CSV file triggers the rule once with the row data. 

Check rule logs
Rule log for bulk archive user in xFanatical Foresight
  • Verify the result

In the Google Admin Console > Users list or the individual User information page, the statuses for the users display Archived

Verify the result
User archived in Google Admin

In your Gmail > Sent folder, you would find emails sent to the respective managers of archived users. Each manager gets one email for each of their archived employees. 

archived employees
Email sent to managers in Gmail Sent folder

Now, that was powerful automation, wasn’t it? Create multiple workflows like this and make your work a lot easier than it is.

Notes

  • The cost per rule execution costs 4 actions if a user has a manager, otherwise 3 actions. If you're certain every user has a manager, then take out the If action and attach the Email as the direct next action of Archive user action.
  • The use case in this article is an intermediate level workflow. If you do not need to notify managers at all, the rule is far simpler to configure. Create a rule with the Data uploaded trigger and Archive user action and then upload the CSV file.
Archive user
Simplified archive user rule in xFanatical Foresight
  • Once your rule is set, you can upload new CSV files to archive more batches of users without editing the rule.
  • Your CSV file cannot exceed 1000 data rows, excluding the header row. If you do have over 1000  users to archive in your large organization, consider splitting the mega CSV file into smaller CSV files. 
  • Alternatively, it's doable to continuously bulk archiving users without a CSV file or logging to Foresight. Create a rule with the User's organizational unit changed trigger and the Archive user action. With a little tweak of the rule, you can archive users just by multi-selecting and moving the users to a given organizational unit (OU) in the Google Admin > Users page. It surely frees your valuable time.
User's organizational unit changed
Continuous bulk archive user in xFanatical Foresight
  • By replacing the Archive user action with the Unarchive user action, the coin flips into bulk unarchiving Google Workspace users. 

Conclusion

To sum up, hopefully, this write-up has managed to give a brief idea of how our product Foresight can make a tangible difference in your workflow that too without any major complications. You can revisit the blog section for more such informative posts.

Try a 14-day free trial with Foresight and manage your tasks. For more article please visit our website: Articles