# Getting Started (old)

## What You'll Need

{% stepper %}
{% step %}

### API Key

Get an API key from your [Synth Dashboard](https://dashboard.synthdata.co/).
{% endstep %}

{% step %}

### Make a Request

```bash
curl "https://api.synthdata.co/v2/prediction/best?asset=BTC&time_increment=300&time_length=86400" \
  -H "Authorization: Apikey YOUR_API_KEY"
```

{% endstep %}

{% step %}

### Parse the Response

```python
import requests
import numpy as np

response = requests.get(
    "https://api.synthdata.co/v2/prediction/best",
    headers={"Authorization": "Apikey YOUR_API_KEY"},
    params={
        "asset": "BTC",
        "time_increment": 300,
        "time_length": 86400
    }
)

data = response.json()[0]
paths = data['predictions']

# Calculate probability
current_price = paths[0][0]
final_prices = [path[-1] for path in paths]
prob_up = sum(1 for p in final_prices if p > current_price) / len(final_prices)

print(f"Current: ${current_price:,.2f}")
print(f"24h Median: ${np.median(final_prices):,.2f}")
print(f"Prob up: {prob_up:.1%}")
```

{% endstep %}
{% endstepper %}

## Common Parameters

| Parameter        | Value                                       | Description              |
| ---------------- | ------------------------------------------- | ------------------------ |
| `asset`          | `BTC`, `ETH`, `SOL`, `XAU`, `SPYX`, `NVDAX` | Asset to forecast        |
| `time_increment` | `300`                                       | 5-minute intervals       |
| `time_length`    | `86400`                                     | 24-hour forecast horizon |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.synthdata.co/getting-started-old.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
