---
title: "Register Service Api"
method: POST
path: "/api/servers/register"
tags: ["Server Management"]
---

# Register Service Api

`POST /api/servers/register`

Register a service via JWT Bearer Token authentication (External API).

This endpoint provides the same functionality as POST /api/internal/register
but uses modern JWT Bearer token authentication via nginx headers, making it
suitable for external service-to-service communication.

**Authentication:** JWT Bearer token (via nginx X-User header)
**Authorization:** Requires valid JWT token from auth system

**Request body (form data):**
- `name` (required): Service name
- `description` (required): Service description
- `path` (required): Service path (e.g., /myservice)
- `proxy_pass_url` (required): Proxy URL (e.g., http://localhost:8000)
- `tags` (optional): Comma-separated tags
- `num_tools` (optional): Number of tools
- `num_stars` (optional): Star rating
- `is_python` (optional): Is Python server (boolean)
- `license` (optional): License name
- `overwrite` (optional): Overwrite if exists (boolean, default true)
- `auth_provider` (optional): Auth provider name
- `auth_type` (optional): Auth type (e.g., oauth, basic)
- `supported_transports` (optional): JSON array of transports
- `headers` (optional): JSON object of headers
- `tool_list_json` (optional): JSON array of tool definitions

**Response:**
- `201 Created`: Service registered successfully
- `400 Bad Request`: Invalid input data
- `401 Unauthorized`: Missing or invalid JWT token
- `409 Conflict`: Service already exists (unless overwrite=true)
- `500 Internal Server Error`: Server error

**Example:**
```bash
curl -X POST https://registry.example.com/api/servers/register \
  -H "Authorization: Bearer $JWT_TOKEN" \
  -F "name=My Service" \
  -F "description=My MCP Service" \
  -F "path=/myservice" \
  -F "proxy_pass_url=http://localhost:8000"
```

## Response `200`

Successful Response

- unknown

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/ascending-llc/apis/mcp-gateway-registry.md) · [All operations](https://skmtc.net/ascending-llc/apis/mcp-gateway-registry/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ascending-llc/mcp-gateway-registry/versions/31381943e2e7/schema)
