How to use Cpanel Automation Plugin to Automate Database Creation for Shared Hosting

⌘K
  1. Home
  2. Docs
  3. Nazmart – Multi-Ten...
  4. General Questions
  5. How to use Cpanel Automation Plugin to Automate Database Creation for Shared Hosting

How to use Cpanel Automation Plugin to Automate Database Creation for Shared Hosting

Nazmart allows you to automate the database creation process for each newly registered store by integrating your cPanel API. This step-by-step guide will walk you through generating a cPanel API token and configuring it within the Nazmart admin panel.

Step 1: Create a cPanel API Token

  1. Log in to your cPanel account.
  2. In the top search bar, type manage API.
  3. From the list, click on Manage API Tokens under the Tools section.
  1. On the API Tokens page, click the Create button.
  1. Enter a token name (e.g., nazmart-token) in the field labeled “API Token Name”.
  2. Choose whether the token will expire:
    • Select The API Token will not expire, or
    • Choose Specify an expiration date if needed.
  3. Click Create to generate the token.
  1. Copy and securely store the generated token. You will not be able to view it again after this step.

Step 2: Configure cPanel API Token in Nazmart Admin Panel

  1. Log in to your Nazmart Super Admin Panel.
  2. Navigate to the Cpanel Automation section from the left sidebar.
  3. Set the Enable or Disable option to YES.
  4. Fill in the required fields:
    • Cpanel URL: For example, https://yourdomain.com:2083
    • Cpanel Username: Your cPanel account username
    • Cpanel Token: Paste the token generated in Step 1
  5. Click Save Changes to apply the configuration.

Step 3: Verify with Test Database Creation

After saving the settings:

  1. Click the Create Test Database button available in the Cpanel Automation section.
  2. This will trigger a test request to cPanel to ensure that the integration is working correctly.

Notes

  • Your hosting provider must support cPanel API functionality.
  • The token should have privileges to create databases and users.
  • Ensure the correct port (2083) is used in the cPanel URL.
  • Never share your token. Treat it as a secure credential.

With this configuration, Nazmart will handle database creation automatically for each new store without manual involvement.

Was this article helpful to you? No Yes

How can we help?