Bulk Import Websites for Customers

If you're needing to bulk-import websites for a specific customer, we've made a simple script to handle this, rather than having to add each one to the UI individually.

=====================================================

  1. Create a simple CSV with a list of all of websites you want to import (just the urls on each line, don't need any other data) and save it somewhere easy to call from PowerShell (eg. C:\temp\websites.csv)

  2. Download the script file

    1. Save it somewhere easy to run, such as C:\temp\HuduBulkWebsiteImporter.ps1

  3. Open PowerShell as Administrator

    1. Depending on your computer's policies, you may have to set your ExecutionPolicy to allow the script

      1. Run this command and hit enter: Set-ExecutionPolicy RemoteSigned -Scope CurrentUser

        1. When asked, type Y and press Enter.

  4. Run the Script

    1. In PowerShell change directory to where you saved the script, then call the script:

      1. eg. cd C:\temp

      2. .\HuduBulkWebsiteImporter.ps1

  5. Answer the Questions

    1. The script will prompt you with options one at a time:

      1. Hudu URL

        1. Example: https://yourcompany.huducloud.com

      2. CSV File Path (where your file is saved)

        1. eg. C:\temp\websites.csv

    2. Hudu API Key

      1. Paste in your API key (from Hudu settings).

        1. (yourcompany.huducloud.com/admin/api_keys)

    3. Company Name

      1. Type the company name exactly as shown in Hudu.

    4. Domain Features

      1. The script will prompt you about enabling or disabling features (DNS, SSL, WHOIS, DMARC, DKIM, SPF). You can choose to enable them all, disable them all, or choose each option.

  6. The script will tell you how many websites were created, skipped, or failed.

  7. Check in Hudu

    1. Log into Hudu, open the company, and look under Websites.

    2. If some failed, read the "Skip Report" the script shows. It explains why and how to fix.

HuduBulkWebsiteImporter.ps1
16.86KB
4