# TEFAS API Scraper · Turkish Mutual Funds (Fonoloji) (`akemal/tefas-api-scraper`) Actor

Structured JSON API for TEFAS — 600+ Turkish mutual funds, NAV history, Sharpe, volatility, KAP holdings, category stats. AI-enriched by Fonoloji. Free demo: 5 funds/req, 100 req/IP/day. More: fonoloji.com/api-docs · TR fonları için ücretsiz JSON API.

- **URL**: https://apify.com/akemal/tefas-api-scraper.md
- **Developed by:** [Ali Kemal](https://apify.com/akemal) (community)
- **Categories:** MCP servers
- **Stats:** 3 total users, 2 monthly users, 6.9% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

## 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.md):

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

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.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/platform/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

## TEFAS API Scraper · Turkish Mutual Funds

Structured JSON API for **TEFAS** (Turkish Electronic Fund Trading Platform).
600+ active Turkish mutual funds with NAV history, performance metrics
(Sharpe, volatility, returns), KAP portfolio holdings, and category
statistics. AI-enriched analytics powered by [Fonoloji](https://fonoloji.com).

### ⚠ Apify Limits (Demo Tier)

- **5 funds / request**
- **30 NAV points / request**
- **1 fund / holdings request**
- **100 requests / IP / day**

For higher limits (100 funds/req, 365 NAV points, 3,000 req/day) sign up
**free** at 👉 **[fonoloji.com/api-docs](https://fonoloji.com/api-docs?ref=apify)**

### 🎯 Endpoints

| Endpoint | Description |
|---|---|
| `funds` | List of active funds (filter by category, search) |
| `fund_detail` | Single fund with latest metrics |
| `fund_history` | NAV history (max 30 days lookback) |
| `fund_holdings` | KAP portfolio composition (latest report) |
| `movers` | Top 5 gainers / losers (1d, 1w, 1m, 3m, 1y) |
| `categories` | Category statistics |

### 📦 Output

All results pushed to Apify Dataset, downloadable as JSON / CSV / Excel.

Example `funds` output:
```json
{
  "code": "AFA",
  "name": "AK PORTFÖY HİSSE FONU",
  "category": "Hisse Senedi Yoğun",
  "management_company": "Ak Portföy",
  "price": 12.34,
  "return_1d": 0.0123,
  "return_1m": 0.0567,
  "aum": 1234567890,
  "investor_count": 45678,
  "sharpe_90": 1.42,
  "volatility_90": 0.18
}
````

### 🔐 License

Free public tier of **Fonoloji Fund Analytics**. Data: TEFAS public + Fonoloji
AI-enriched dataset. **Redistribution prohibited** without written consent.
Personal & enterprise analysis use only. **Not investment advice.**

### 🔗 Links

- Web: [fonoloji.com](https://fonoloji.com)
- API docs & higher limits: [fonoloji.com/api-docs](https://fonoloji.com/api-docs?ref=apify)
- Contact: [fonoloji.com/iletisim](https://fonoloji.com/iletisim)

***

### 🇹🇷 Türkçe

**TEFAS** (Türkiye Elektronik Fon Alım Satım Platformu) için yapılandırılmış JSON API.
600+ aktif Türk yatırım fonunun NAV tarihçesi, performans metrikleri
(Sharpe, volatilite, getiri), KAP portföy dağılımları ve kategori
istatistikleri. [Fonoloji](https://fonoloji.com) tarafından AI ile zenginleştirilmiş analytics.

#### ⚠ Apify Limitleri (Demo)

- **5 fon / istek**
- **30 NAV nokta / istek**
- **1 fon / portföy isteği**
- **100 istek / IP / gün**

Daha yüksek limit (100 fon/istek, 365 NAV nokta, 3.000 istek/gün) için
**ücretsiz** üyelik 👉 **[fonoloji.com/api-docs](https://fonoloji.com/api-docs?ref=apify)**

#### 🎯 Endpoint'ler

| Endpoint | Açıklama |
|---|---|
| `funds` | Aktif fonların listesi (kategori, arama filter) |
| `fund_detail` | Tek fon detayı + en son metrics |
| `fund_history` | NAV tarihçesi (max 30 gün lookback) |
| `fund_holdings` | KAP portföy dağılımı (en son rapor) |
| `movers` | En çok yükselen/düşen 5 fon (1g, 1h, 1a, 3a, 1y) |
| `categories` | Kategori istatistikleri |

#### 🔐 Veri Lisansı

Bu aktör **Fonoloji Fund Analytics**'in halka açık ücretsiz katmanıdır.
Veri: TEFAS public + Fonoloji AI-enriched dataset.
**Yeniden satışı yasaktır**, kişisel/kurumsal analiz amaçlı kullanılır.
**Yatırım tavsiyesi değildir.**

# Actor input Schema

## `endpoint` (type: `string`):

Which data type? · Hangi veri tipi?

## `fundCodes` (type: `array`):

TEFAS fund codes for detail/history/holdings (e.g. AFA, AKE, ASN). Max 5 (Apify limit). Leave empty for funds list. · Detay/history/holdings için fon kodları. Maks 5 (Apify limiti).

## `search` (type: `string`):

Fund name or code · Fon adı veya kodu

## `category` (type: `string`):

e.g. Hisse Senedi Yoğun, Para Piyasası, Borçlanma, Karma · Örn: Hisse Senedi Yoğun

## `fromDate` (type: `string`):

YYYY-MM-DD format. Apify max 30 days lookback. · YYYY-MM-DD formatı.

## `toDate` (type: `string`):

YYYY-MM-DD format · YYYY-MM-DD formatı

## `period` (type: `string`):

Period for top movers · En yükselen/düşen için periyot

## Actor input object example

```json
{
  "endpoint": "funds",
  "fundCodes": [],
  "period": "1d"
}
```

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("akemal/tefas-api-scraper").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("akemal/tefas-api-scraper").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 '{}' |
apify call akemal/tefas-api-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "TEFAS API Scraper · Turkish Mutual Funds (Fonoloji)",
        "description": "Structured JSON API for TEFAS — 600+ Turkish mutual funds, NAV history, Sharpe, volatility, KAP holdings, category stats. AI-enriched by Fonoloji. Free demo: 5 funds/req, 100 req/IP/day. More: fonoloji.com/api-docs · TR fonları için ücretsiz JSON API.",
        "version": "1.0",
        "x-build-id": "ZesvhHmrR2m4zaGf9"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/akemal~tefas-api-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-akemal-tefas-api-scraper",
                "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/akemal~tefas-api-scraper/runs": {
            "post": {
                "operationId": "runs-sync-akemal-tefas-api-scraper",
                "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/akemal~tefas-api-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-akemal-tefas-api-scraper",
                "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": [
                    "endpoint"
                ],
                "properties": {
                    "endpoint": {
                        "title": "Endpoint",
                        "enum": [
                            "funds",
                            "fund_detail",
                            "fund_history",
                            "fund_holdings",
                            "movers",
                            "categories"
                        ],
                        "type": "string",
                        "description": "Which data type? · Hangi veri tipi?",
                        "default": "funds"
                    },
                    "fundCodes": {
                        "title": "Fund codes / Fon Kodları",
                        "type": "array",
                        "description": "TEFAS fund codes for detail/history/holdings (e.g. AFA, AKE, ASN). Max 5 (Apify limit). Leave empty for funds list. · Detay/history/holdings için fon kodları. Maks 5 (Apify limiti).",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "search": {
                        "title": "Search (funds endpoint only) / Arama",
                        "type": "string",
                        "description": "Fund name or code · Fon adı veya kodu"
                    },
                    "category": {
                        "title": "Category (funds endpoint only) / Kategori",
                        "type": "string",
                        "description": "e.g. Hisse Senedi Yoğun, Para Piyasası, Borçlanma, Karma · Örn: Hisse Senedi Yoğun"
                    },
                    "fromDate": {
                        "title": "From date (fund_history) / Başlangıç Tarihi",
                        "type": "string",
                        "description": "YYYY-MM-DD format. Apify max 30 days lookback. · YYYY-MM-DD formatı."
                    },
                    "toDate": {
                        "title": "To date (fund_history) / Bitiş Tarihi",
                        "type": "string",
                        "description": "YYYY-MM-DD format · YYYY-MM-DD formatı"
                    },
                    "period": {
                        "title": "Period (movers) / Dönem",
                        "enum": [
                            "1d",
                            "1w",
                            "1m",
                            "3m",
                            "1y"
                        ],
                        "type": "string",
                        "description": "Period for top movers · En yükselen/düşen için periyot",
                        "default": "1d"
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
