> ## Documentation Index
> Fetch the complete documentation index at: https://redop.useagents.site/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Your First Server

> Build and run a minimal Redop server before you add schemas, middleware, resources, prompts, or auth.

This is the fastest way to get a Redop server working end to end.

## Copy this example

```ts theme={null}
import { Redop } from "@redopjs/redop";

new Redop({
  serverInfo: {
    name: "hello-redop",
    version: "0.1.0",
  },
})
  .tool("ping", {
    description: "Health check",
    handler: () => ({ pong: true, ts: Date.now() }),
  })
  .listen(3000);
```

## What each part does

* `new Redop(...)` defines the server identity returned during `initialize`
* `serverInfo` groups the MCP-facing metadata for the server
* `.tool(...)` registers one MCP tool
* the handler returns plain serializable data
* `.listen(3000)` starts the HTTP transport on port `3000`

## Run it

```sh theme={null}
bun run --watch src/index.ts
```

Once it starts, your MCP endpoint will be available at `http://localhost:3000/mcp`.

## Verify the result

* send `initialize` to `http://localhost:3000/mcp`
* confirm your client can discover the `ping` tool
* keep the server small until the transport works cleanly

## Next

* [Connect over HTTP](/docs/getting-started/connect-http)
* [Connect over stdio](/docs/getting-started/connect-stdio)
* [Verify with local clients](/docs/getting-started/verify-clients)
