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

# EP Ratio Screener Server

> Fundamental stock screening based on earnings yield and balance-sheet quality.

## Overview

The EP Ratio Screener Server runs a fundamental stock screener based on normalized earnings yield, balance-sheet health, ROIC, earnings consistency, and yield spread versus the risk-free rate.

## Connection

Add this server to your MCP client configuration.

<Tabs>
  <Tab title="Cursor">
    ```json theme={null}
    {
      "mcpServers": {
        "ep-ratio-screener": {
          "url": "https://ep-ratio-screener-production.up.railway.app/mcp/epratioscreener"
        }
      }
    }
    ```
  </Tab>

  <Tab title="Bearer auth">
    ```json theme={null}
    {
      "mcpServers": {
        "ep-ratio-screener": {
          "url": "https://ep-ratio-screener-production.up.railway.app/mcp/epratioscreener",
          "headers": {
            "Authorization": "Bearer ${env:EP_RATIO_SCREENER_MCP_TOKEN}"
          }
        }
      }
    }
    ```
  </Tab>
</Tabs>

Restart the client after changing MCP configuration. The server tools appear automatically after the connection is established.

## Transport

| Property         | Value                                                                     |
| ---------------- | ------------------------------------------------------------------------- |
| Protocol         | MCP over Streamable HTTP                                                  |
| MCP URL          | `https://ep-ratio-screener-production.up.railway.app/mcp/epratioscreener` |
| Health URL       | `https://ep-ratio-screener-production.up.railway.app/health`              |
| MCP path         | `/mcp/epratioscreener`                                                    |
| Request envelope | `{"request": {...}}`                                                      |
| Auth             | Optional bearer token when enabled for the endpoint                       |

## Best-Fit Workflows

* Validate runtime configuration before screening.
* Score one ticker with the E/P-based decision pipeline.
* Screen a batch of tickers and export CSV outputs.
* Check whether the service is running in full-data or fallback mode.

## Recommended Tools

* config-validate
* scoring-engine-score
* screen-tickers

## Tools

| Tool                   | Description                                                                                                                                                                                                                                                                     | Returns          |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------- |
| `config-validate`      | Validates the current EPRatio Screener configuration. Params: none                                                                                                                                                                                                              | `Any`            |
| `scoring-engine-score` | Scores a ticker using the EPRatio screener scoring engine. Params: ticker (str): ticker symbol to score                                                                                                                                                                         | `Any`            |
| `screen-tickers`       | Run the EPRatio screening workflow and save results as CSV files. Outputs a full results CSV and a filtered passing CSV sorted by yield spread. Params: tickers: optional list of ticker symbols; use\_fmp\_screen: if True, overrides tickers and uses FMP's screened universe | `dict[str, Any]` |

## Examples

### Validate config

```json theme={null}
{
  "request": {}
}
```

### Score one ticker

```json theme={null}
{
  "request": {
    "ticker": "MSFT"
  }
}
```

### Screen a batch

```json theme={null}
{
  "request": {
    "tickers": [
      "MSFT",
      "AAPL",
      "JPM"
    ],
    "use_fmp_screen": false
  }
}
```

## n8n Workflow

This server can be called from an n8n schedule or `POST` Webhook to run a ticker screen and return a ranked JSON report.

Recommended n8n HTTP Request chain:

1. Accept `tickers` and `use_fmp_screen` from the webhook body, or use a scheduled default universe.
2. Initialize the MCP session and store `MCP-Session-Id`.
3. Call `load_skills` once when the endpoint requires skill bootstrap.
4. Split larger ticker lists into batches.
5. Call `screen-tickers` with `{"request":{"tickers":[...],"use_fmp_screen":false}}`.
6. Parse the SSE response, combine batch results, and route the output to Respond to Webhook or delivery nodes.

Use n8n Credentials for any delivery channel. Do not export private webhook paths, email addresses, or OAuth credential references with workflow JSON.

See [n8n Workflows](/quantx/servers/deployed/n8n-workflows) for the shared webhook and MCP session patterns.

Available n8n template:

* [EP Ratio Screener JSON](/quantx/servers/deployed/workflows/ep-ratio-screener.json) - public ticker-screen webhook at `POST https://n8n.limex.pro/webhook/a1b2c3d4-e5f6-7890-abcd-ef1234567890`. The template removes the scheduled email-delivery branch; add your own delivery nodes after import.

## Notes

* `use_fmp_screen=true` requires the optional FMP data source to be configured.
* Fallback mode still supports the core scoring flow, but has less universe/enrichment coverage.

<CardGroup cols={3}>
  <Card title="Client setup" icon="plug" href="/quantx/servers/deployed/client-setup">
    Configure this endpoint in Cursor, Claude Desktop, or a generic MCP client.
  </Card>

  <Card title="n8n workflows" icon="workflow" href="/quantx/servers/deployed/n8n-workflows">
    Build webhook and scheduled screening flows around this MCP endpoint.
  </Card>

  <Card title="Shared tools" icon="wrench" href="/quantx/servers/deployed/shared-tools">
    Use health, result, artifact, environment, and table helper tools.
  </Card>
</CardGroup>

## Other Servers

<CardGroup cols={3}>
  <Card title="Dataloader" icon="server" href="/quantx/servers/dataloader">
    Market-data retrieval, TA-Lib indicators, and dataframe exports.
  </Card>

  <Card title="Fama-French Replicate" icon="server" href="/quantx/servers/fama-french-replicate">
    Official and replicated Fama-French factors plus loadings and alpha estimation.
  </Card>

  <Card title="Statistical Factor Models" icon="server" href="/quantx/servers/statistical-factor-models">
    Stock-Watson, complete-panel, and dynamic statistical factor extraction.
  </Card>

  <Card title="Jump Models" icon="server" href="/quantx/servers/jump-models">
    JumpModel and SparseJumpModel regime fitting, online prediction, and backtesting.
  </Card>

  <Card title="Wavelet Mean Reversion" icon="server" href="/quantx/servers/wavelet-mean-reversion">
    Wavelet-based mean reversion analysis for financial time series.
  </Card>

  <Card title="Parallax ExtremeHurst" icon="server" href="/quantx/servers/parallax-extreme-hurst">
    ExtremeHurst signal generation from OHLCV data.
  </Card>

  <Card title="Volatility Scaling Lab" icon="server" href="/quantx/servers/volatility-scaling-lab">
    Volatility targeting, EWMA volatility, Monte Carlo bands, and risk diagnostics.
  </Card>
</CardGroup>
