You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
}).Warn("TFE tool called but session has no valid TFE client")
128
128
129
129
returnmcp.NewToolResultError("This tool is not available. This tool requires a valid Terraform Cloud/Enterprise token and configuration. Please ensure TFE_TOKEN and TFE_ADDRESS environment variables are properly set."), nil
130
130
}
131
-
132
131
// If we found a valid client that wasn't registered, register it now
logger.WithError(err).Error("failed to render module template")
94
+
}
95
+
moduleList+=moduleBuilder.String()
77
96
}
78
97
79
98
ifpolicy.Type=="policies" {
@@ -85,13 +104,30 @@ module "%s" {
85
104
builder.WriteString("## Usage\n\n")
86
105
builder.WriteString("Generate the content for a HashiCorp Configuration Language (HCL) file named policies.hcl. This file should define a set of policies. For each policy provided, create a distinct policy block using the following template.\n")
87
106
builder.WriteString("\n```hcl\n")
88
-
hclTemplate:=fmt.Sprintf(`
89
-
%s
107
+
// Use text/template to safely build the HCL template for policies
// get_provider_docsV2 retrieves a list of documentation items for a specific provider category using v2 API with support for pagination using page numbers
builder.WriteString("Each result includes:\n- providerDocID: tfprovider-compatible identifier\n- Title: Service or resource name\n- Category: Type of document\n- Description: Brief summary of the document\n")
226
227
builder.WriteString("For best results, select libraries based on the service_slug match and category of information requested.\n\n---\n\n")
0 commit comments