Problem
When using the Terraform Enterprise API endpoint /organizations/:organization_name/registry-modules, you receive a 404 error response.
{
"errors": [
{
"status": "404",
"title": "not found"
}
]
}Cause
This error can occur for two primary reasons:
- The Terraform Enterprise instance is running on a version older than
v202106-1, which is when this API endpoint was introduced. - The specified registry modules do not exist, or the user or token making the API call lacks the required permissions to access them.
Solutions
Solution 1: Upgrade Terraform Enterprise
The API endpoint for registry modules was introduced in Terraform Enterprise version v202106-1. To resolve the issue, upgrade your Terraform Enterprise instance to version v202106-1 or a more recent version.
Solution 2: Verify Module Existence and Permissions
If your instance is already on a supported version, confirm that the registry modules exist and that the user or token performing the action has the necessary permissions to access them.