# Stock, Crypto & Forex Screener (`goat255/stock-screener`) Actor

Screen any market with your own filters and columns. Returns a ranked table of matching tickers with the exact data fields you request.

- **URL**: https://apify.com/goat255/stock-screener.md
- **Developed by:** [Goutam Soni](https://apify.com/goat255) (community)
- **Categories:** Business
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$1.00 / 1,000 ticker returneds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js/docs.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python/docs.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Stock, Crypto & Forex Screener

Screen any market with your own filters and columns, and get back a ranked table of matching tickers. Pick the market, choose exactly which data fields you want, add optional numeric filters, and rank the results by any column. Works for equities, crypto pairs, and forex pairs from a single input.

Use it to build watchlists, feed a trading dashboard, power lead lists of companies by market cap or sector, or run scheduled screens for movers and gainers.

### What you get

- One row per ticker, ranked by the column you choose.
- Every column you request, labelled and returned in order.
- A stable `symbol` (exchange + ticker) and a `rank` on every row.
- Any market: equities across dozens of countries, crypto, and forex.

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `market` | string | `america` | Market to screen. E.g. `america`, `crypto`, `forex`, `uk`, `india`, `germany`, `japan`, `canada`, `australia`. |
| `columns` | array | `["name","close","change","volume","market_cap_basic"]` | Data fields to return per ticker, in order. |
| `sortBy` | string | `market_cap_basic` | Column to rank by. Use a numeric column (for crypto/forex use `volume` or `change`). |
| `sortOrder` | string (`desc`/`asc`) | `desc` | Ranking direction. |
| `limit` | integer | `50` | Number of tickers to return (1 to 500). |
| `filters` | array | `[]` | Optional numeric filters to narrow the screen. |

#### Common columns

`name`, `close`, `change`, `change_abs`, `volume`, `market_cap_basic`, `price_earnings_ttm`, `dividend_yield_recent`, `sector`, `industry`, `RSI`, `exchange`, `description`.

#### Example input

```json
{
  "market": "america",
  "columns": ["name", "close", "change", "volume", "market_cap_basic", "sector"],
  "sortBy": "market_cap_basic",
  "sortOrder": "desc",
  "limit": 50,
  "filters": [
    { "left": "market_cap_basic", "operation": "greater", "right": 1000000000 }
  ]
}
````

### Output

Each dataset row contains `symbol`, `rank`, and one key per requested column.

| Field | Description |
|---|---|
| `symbol` | Exchange-qualified ticker, e.g. `NASDAQ:AAPL`. |
| `rank` | Position in the ranked result (1 = top). |
| `name` | Ticker symbol / short name (when requested). |
| `close` | Latest price (when requested). |
| `change` | Percent change (when requested). |
| `volume` | Traded volume (when requested). |
| `market_cap_basic` | Market capitalization (when requested). |
| ...any other requested column | Returned under its own key. |

#### Example output row

```json
{
  "symbol": "NASDAQ:AAPL",
  "rank": 2,
  "name": "AAPL",
  "close": 317.31,
  "change": 0.63,
  "volume": 43257535,
  "market_cap_basic": 4660445181914.07
}
```

### Pricing

This Actor uses pay per event:

| Event | Price (USD) |
|---|---|
| Ticker returned | $0.001 per ticker row |

You are charged once per ticker row returned in the ranked table. A screen returning 50 tickers costs $0.05.

### Notes

- `columns` are returned in the exact order you request them, each under its own key.
- For crypto and forex, market-cap ranking is not meaningful. Sort by `volume` or `change` instead.
- `filters` accept objects like `{ "left": "<column>", "operation": "greater", "right": <number> }`. Leave empty to screen the whole market.

**Found this useful?** [Leave a quick review](https://apify.com/goat255/stock-screener/reviews). It takes a few seconds and it genuinely helps other people find the actor.

# Actor input Schema

## `market` (type: `string`):

The market to screen. Common values: america, crypto, forex, uk, india, germany, japan, canada, australia, france, italy, spain, brazil, china, hongkong, korea, russia, turkey, uae. Any market slug supported by the data source works.

## `columns` (type: `array`):

The data fields to return for each ticker, in order. Examples: name, close, change, change\_abs, volume, market\_cap\_basic, price\_earnings\_ttm, dividend\_yield\_recent, sector, industry, RSI, exchange, description.

## `sortBy` (type: `string`):

The column to rank results by. Should be a numeric column (e.g. market\_cap\_basic, volume, change, close). For crypto/forex where market cap is not available, use volume or change.

## `sortOrder` (type: `string`):

Ranking direction.

## `limit` (type: `integer`):

How many matching tickers to return.

## `filters` (type: `array`):

Optional raw filter objects to narrow the screen, each like {"left":"market\_cap\_basic","operation":"greater","right":1000000000}. Leave empty to screen the whole market.

## Actor input object example

```json
{
  "market": "america",
  "columns": [
    "name",
    "close",
    "change",
    "volume",
    "market_cap_basic"
  ],
  "sortBy": "market_cap_basic",
  "sortOrder": "desc",
  "limit": 50,
  "filters": []
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "columns": [
        "name",
        "close",
        "change",
        "volume",
        "market_cap_basic"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("goat255/stock-screener").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "columns": [
        "name",
        "close",
        "change",
        "volume",
        "market_cap_basic",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("goat255/stock-screener").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "columns": [
    "name",
    "close",
    "change",
    "volume",
    "market_cap_basic"
  ]
}' |
apify call goat255/stock-screener --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=goat255/stock-screener",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Stock, Crypto & Forex Screener",
        "description": "Screen any market with your own filters and columns. Returns a ranked table of matching tickers with the exact data fields you request.",
        "version": "0.1",
        "x-build-id": "U4hFoV0G4VBdKjXDI"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/goat255~stock-screener/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-goat255-stock-screener",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/goat255~stock-screener/runs": {
            "post": {
                "operationId": "runs-sync-goat255-stock-screener",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/goat255~stock-screener/run-sync": {
            "post": {
                "operationId": "run-sync-goat255-stock-screener",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "market"
                ],
                "properties": {
                    "market": {
                        "title": "Market",
                        "type": "string",
                        "description": "The market to screen. Common values: america, crypto, forex, uk, india, germany, japan, canada, australia, france, italy, spain, brazil, china, hongkong, korea, russia, turkey, uae. Any market slug supported by the data source works.",
                        "default": "america"
                    },
                    "columns": {
                        "title": "Data columns",
                        "type": "array",
                        "description": "The data fields to return for each ticker, in order. Examples: name, close, change, change_abs, volume, market_cap_basic, price_earnings_ttm, dividend_yield_recent, sector, industry, RSI, exchange, description.",
                        "default": [
                            "name",
                            "close",
                            "change",
                            "volume",
                            "market_cap_basic"
                        ],
                        "items": {
                            "type": "string"
                        }
                    },
                    "sortBy": {
                        "title": "Sort by column",
                        "type": "string",
                        "description": "The column to rank results by. Should be a numeric column (e.g. market_cap_basic, volume, change, close). For crypto/forex where market cap is not available, use volume or change.",
                        "default": "market_cap_basic"
                    },
                    "sortOrder": {
                        "title": "Sort order",
                        "enum": [
                            "desc",
                            "asc"
                        ],
                        "type": "string",
                        "description": "Ranking direction.",
                        "default": "desc"
                    },
                    "limit": {
                        "title": "Number of tickers",
                        "minimum": 1,
                        "maximum": 500,
                        "type": "integer",
                        "description": "How many matching tickers to return.",
                        "default": 50
                    },
                    "filters": {
                        "title": "Filters (advanced)",
                        "type": "array",
                        "description": "Optional raw filter objects to narrow the screen, each like {\"left\":\"market_cap_basic\",\"operation\":\"greater\",\"right\":1000000000}. Leave empty to screen the whole market.",
                        "default": []
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
