Skip to main content
Glama
RestDB

Codehooks.io MCP Server

by RestDB

deploy_code

Deploy JavaScript code to create serverless APIs and backends on Codehooks.io, enabling instant CRUD operations and database management.

Instructions

Deploy JavaScript code to Codehooks.io project.

MINIMAL WORKING EXAMPLE:

import { app } from 'codehooks-js';

app.get('/hello', (req, res) => {
  res.json({ message: 'Hello, world!' });
});

// MANDATORY: bind to serverless runtime
export default app.init();

INSTANT CRUD BACKEND:

import { app } from 'codehooks-js';

// Creates complete CRUD API for any collection (no schema required)
app.crudlify();

export default app.init();

KEY REQUIREMENTS:

  • Always import from 'codehooks-js'

  • Always end with export default app.init();

  • Use app.get(), app.post(), app.put(), app.delete() for routes

  • For database: const conn = await Datastore.open(); conn.insertOne(collection, data);

  • Use app.crudlify() to create complete CRUD backend with no schema required

  • Package.json will be auto-generated if not provided

DOCUMENTATION:

  • Use 'docs' tool for more information

  • Online ChatGPT prompt: https://codehooks.io/docs/chatgpt-backend-api-prompt

  • Online Workflow API: https://codehooks.io/docs/workflow-api

  • LLM-optimized docs: https://codehooks.io/llms.txt and https://codehooks.io/llms-full.txt

Note: Codehooks.io has CORS built-in by default, so no additional CORS middleware is needed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filesYesArray of files to deploy
mainNoApplication main file (defaults to 'index')
jsonNoOutput JSON format
projectIdNoProject ID
spaceIdNoSpace IDdev
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden and does well by disclosing behavioral traits: it explains mandatory code patterns (import, export), CORS handling, auto-generated package.json, and references external documentation. It doesn't cover rate limits, authentication needs, or error handling, but provides substantial operational context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose, but includes extensive code examples and documentation links that may be excessive. While informative, some sections (like full code blocks and multiple external links) could be streamlined without losing essential guidance for tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 5 parameters with full schema coverage but no annotations or output schema, the description provides good context: it explains what the tool does, includes working examples, key requirements, and documentation references. It adequately compensates for missing structured fields, though lacks details on return values or error cases.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description doesn't add specific parameter semantics beyond what the schema provides (e.g., it doesn't explain 'files' array structure or 'main' file implications), but the code examples implicitly illustrate how parameters might be used in context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool deploys JavaScript code to Codehooks.io projects with specific examples. It distinguishes from siblings by focusing on code deployment rather than database operations or file management, though it doesn't explicitly contrast with alternatives like 'file_upload'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides implied usage through code examples and key requirements, suggesting when to use this tool for backend deployment. However, it lacks explicit guidance on when to choose this over sibling tools like 'file_upload' or 'docs', and doesn't mention prerequisites or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/RestDB/codehooks-mcp-server'

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