Namecheap icon

Namecheap

Consume Namecheap API

Overview

This node integrates with the Namecheap API to manage domain-related operations. Specifically, for the Domain resource and the Set Registrar Lock operation, it allows users to lock or unlock a domain at the registrar level. Registrar locking is a security feature that prevents unauthorized domain transfers or modifications by locking the domain status.

Common scenarios where this node is beneficial include:

  • Securing domains against unauthorized transfer by enabling the registrar lock.
  • Temporarily unlocking a domain to allow legitimate transfers or updates.
  • Automating domain management workflows that require toggling the lock status based on business rules.

For example, a user might automate locking all their domains after purchase or unlock a domain just before transferring it to another registrar.

Properties

Name Meaning
Domain Name The fully qualified domain name (e.g., "example.com") on which to perform the operation.
Lock Status Boolean value indicating whether to lock (true) or unlock (false) the domain.

Output

The node outputs an array of JSON objects, each corresponding to an input item processed. Each output object has the following structure:

{
  "success": true,
  "data": { /* response data from the Namecheap API for the set registrar lock operation */ }
}
  • success: A boolean indicating if the operation was successful.
  • data: Contains the detailed response from the Namecheap API related to setting the registrar lock status.

If the operation fails and the node is configured to continue on failure, the output will instead contain:

{
  "success": false,
  "error": "Error message describing what went wrong"
}

The node does not output binary data.

Dependencies

  • Requires an active connection to the Namecheap API.
  • Needs an API authentication token or key credential configured in n8n to authorize requests.
  • The node depends on internal classes handling domain operations but these are abstracted away from the user.

Troubleshooting

  • Common issues:

    • Invalid domain name format or non-existent domain may cause API errors.
    • Insufficient permissions or invalid API credentials will result in authentication failures.
    • Trying to lock/unlock a domain that is already in the desired state might return an error or no change.
  • Error messages:

    • "The operation "setRegistrarLock" is not known for resource "domain"!" — indicates a misconfiguration of the operation parameter.
    • API errors returned from Namecheap will be passed through; check the error message for details such as rate limits, invalid parameters, or service outages.
  • Resolution tips:

    • Verify domain names are correctly formatted and registered under your account.
    • Ensure API credentials are valid and have necessary permissions.
    • Use the node’s "continue on fail" option to handle intermittent errors gracefully.

Links and References

Discussion