Skip to main content
Glama

generate_htaccess

Create .htaccess configuration files for Webasyst projects to manage server settings and URL routing.

Instructions

Сгенерировать .htaccess

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
root_pathYes

Implementation Reference

  • The handler function that generates a basic .htaccess file with Apache URL rewriting rules for Webasyst and writes it to the specified root_path.
    async function generateHtaccessTool({ root_path }) { const ht = `<IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php [QSA,L] </IfModule> `; await fs.writeFile(path.join(root_path, '.htaccess'), ht); return { content: [{ type: 'text', text: '.htaccess создан' }] }; }
  • Routes incoming tool calls for 'generate_htaccess' to the corresponding handler function in the CallToolRequest handler.
    case 'generate_htaccess': return await generateHtaccessTool(args);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/emmy-design/webasyst-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server