# Finans haberleri (SBX-FNEWS)

Resmî kaynaklardan finans haberleri: Fed, ECB, ABD şirketlerinin 8-K bildirimleri ve Resmî Gazete; yapay zekâ ile Türkçe ve İngilizce özet, etiket ve önem puanı.

Sürüm: v1.0

## Kimlik doğrulama

API anahtarınızı her istekte Bearer token olarak ya da `apikey` sorgu parametresiyle gönderin:

```
Authorization: Bearer <API_ANAHTARINIZ>
https://api.servicebox.io/v1/finance-news/...?apikey=<API_ANAHTARINIZ>
```

Anahtar almak için https://servicebox.io/signup adresinden kaydolun ve panelden bir anahtar oluşturun. Bir ajan `POST https://api.servicebox.io/v1/accounts` ve `{"email": "...", "apis": ["finance-news"]}` ile kendisi kaydolabilir: e-posta sahibi e-postadaki bağlantıyla onaylar, ajan dönen `poll_url` adresini yoklayarak kısa ömürlü bir anahtar alır.

## Temel URL

`https://api.servicebox.io`

## Uç noktalar

### GET /v1/finance-news/articles

**List articles**

Summarised news items, newest first: each official document (a Fed or ECB release, a listed US company's 8-K, a Resmî Gazete text) with a headline and 2–4 sentence summary in Turkish and English written by AI from that document only, its category, tags, companies, countries, sentiment and importance, and the link to the original. Filters combine; list filters match any of their values.

**Kredi:** çağrı başına 1

**Parametreler**

| Ad | Yer | Tür | Zorunlu | Açıklama |
|---|---|---|---|---|
| `source` | query | string | hayır | Comma-separated source ids from /finance-news/sources. |
| `category` | query | string (`monetary-policy`, `macro-data`, `regulation`, `banking`, `capital-markets`, `corporate`, `earnings`, `m-and-a`, `management`, `debt`, `fiscal`, `trade`, `energy`, `other`) | hayır | One category. |
| `tag` | query | string | hayır | Comma-separated tags, e.g. interest-rates,dividend. |
| `ticker` | query | string | hayır | Comma-separated US tickers (8-K filers), e.g. AAPL,MSFT. |
| `country` | query | string | hayır | Comma-separated ISO 3166-1 alpha-2 codes. |
| `minImportance` | query | integer | hayır | 1–5. |
| `sentiment` | query | string (`positive`, `negative`, `neutral`, `mixed`) | hayır | positive, negative, neutral or mixed. |
| `confident` | query | boolean | hayır | true or false. |
| `since` | query | string | hayır | YYYY-MM-DD or an ISO 8601 UTC time. |
| `until` | query | string | hayır | YYYY-MM-DD or an ISO 8601 UTC time. |
| `limit` | query | integer | hayır | Items per page, 1–200. |
| `cursor` | query | string | hayır | The `next_cursor` of the previous page, with the same filters. |

**Örnek**

```bash
curl "https://api.servicebox.io/v1/finance-news/articles" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/finance-news/articles/{id}

**Get an article**

**Kredi:** çağrı başına 1

**Parametreler**

| Ad | Yer | Tür | Zorunlu | Açıklama |
|---|---|---|---|---|
| `id` | path | string | evet |  |

**Örnek**

```bash
curl "https://api.servicebox.io/v1/finance-news/articles/<id>" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/finance-news/sources

**List sources**

The sources, their licence, and how many summarised articles each has. Free.

**Kredi:** ücretsiz (çağrı başına 0 kredi)

Parametre yok.

**Örnek**

```bash
curl "https://api.servicebox.io/v1/finance-news/sources" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

## Hatalar

Hatalar, makinece okunabilir bir `type` taşıyan RFC 9457 `application/problem+json` gövdeleridir.

- `401` — anahtar eksik, bilinmiyor, süresi dolmuş ya da iptal edilmiş.
- `402` — kredi yetersiz: gövde `credits_required` ve `upgrade_url` (https://servicebox.io/pricing) taşır.
- `403` — anahtarın bu API'yi çağırma izni yok.
- `429` — hız sınırı: `retry_after` saniye bekleyin (`Retry-After` başlığıyla da gönderilir); `upgrade_url` daha büyük bir plana yönlendirir.

## Bağlantılar

- OpenAPI belgesi: https://api.servicebox.io/v1/finance-news/openapi.json
- Fiyatlandırma: https://servicebox.io/pricing?api=SBX-FNEWS
- API sayfası: https://servicebox.io/apis/finance-news
