Actions28
- Domain Actions
- DNS Record Actions
- SSL Actions
- User Actions
Overview
The node integrates with the Namecheap API to manage domain-related operations. Specifically, the "Purchase For User" operation under the "Domain" resource allows purchasing a domain name on behalf of a specified user. This is useful in scenarios where an administrator or reseller needs to register domains for different users programmatically.
Practical examples include:
- Automating domain purchases for customers in a web hosting platform.
- Bulk registering domains for multiple users based on input data.
- Integrating domain registration into a larger workflow that manages user accounts and services.
Properties
| Name | Meaning |
|---|---|
| Username | The username of the user for whom the domain will be purchased. |
| Domain Name | The domain name to be registered (e.g., example.com). |
| Years | Number of years to register the domain for; valid values are from 1 to 10. |
| Registration Options | Collection of optional settings for the domain registration: |
| - Add Free WhoisGuard: Whether to add free WhoisGuard privacy protection (true/false). | |
| - Enable WhoisGuard: Whether to enable WhoisGuard privacy protection (true/false). | |
| - Premium DNS: Whether to enable PremiumDNS service (true/false). | |
| - Auto Renew: Whether to enable auto-renewal of the domain registration (true/false). |
Output
The node outputs a JSON object containing:
success: A boolean indicating if the purchase operation was successful.data: The response data returned by the Namecheap API for the purchase operation, which typically includes details about the purchased domain, confirmation status, and any relevant metadata.
No binary data output is indicated for this operation.
Example output structure:
{
"success": true,
"data": {
// Domain purchase details as returned by Namecheap API
}
}
Dependencies
- Requires an active connection to the Namecheap API via an API key credential configured in n8n.
- The node depends on the Namecheap API being accessible and the credentials having sufficient permissions to perform domain purchases.
- No additional external dependencies beyond the Namecheap API and its authentication.
Troubleshooting
Common issues:
- Invalid or missing API credentials can cause authentication failures.
- Attempting to purchase a domain that is already registered or unavailable will result in errors.
- Providing invalid domain names or usernames may cause validation errors.
- Exceeding allowed registration years (less than 1 or more than 10) will trigger input validation errors.
Error messages:
"The operation "purchaseForUser" is not known for resource "domain"!"— indicates a misconfiguration of the operation parameter.- API error responses related to domain availability or permission issues will be surfaced in the node's output when
continueOnFailis enabled.
Resolution tips:
- Verify API credentials and permissions.
- Ensure domain names are correctly formatted and available.
- Confirm the username exists and is valid within the Namecheap system.
- Use the node’s built-in validation for years and required fields.