# export_fbx()

Exports a single reference slot as an FBX file.

### Signature
```python
api.export_fbx(slot: int, output_path: str, fbx_options: dict = None, preset: str = None) -> dict
```

### Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| `slot` | `int` | Slot number to export (0-9) |
| `output_path` | `str` | Full path for the output `.fbx` file |
| `fbx_options` | `dict` | FBX option overrides (applied after preset, or over defaults if no preset) |
| `preset` | `str` | Saved preset name (e.g. `"Unreal"`, `"Unreal_Ani"`) [v2 new] |

If both `preset` and `fbx_options` are specified, the preset is loaded first and `fbx_options` overrides it.

### Return Value
```python
# success
{"success": True, "message": str, "output_path": str}

# failure
{"success": False, "message": str, "error": str}
```

### Errors
| Error | Cause |
| --- | --- |
| `TypeError` | slot is not int (including bool) [v2 added] |
| `ValueError` | Slot is invalid or empty, output directory does not exist, invalid preset name |
| `TypeError` | `fbx_options` is not `dict` |

### Example
```python
from os_fast_ref.api import FastRefAPI

api = FastRefAPI()

# Default preset
result = api.export_fbx(slot=0, output_path=r"J:\output\character.fbx")

# Named preset (v2)
result = api.export_fbx(slot=0, output_path=r"J:\output\char.fbx", preset="Unreal_Ani")

# Override specific options only
result = api.export_fbx(
    slot=0,
    output_path=r"J:\output\character_skel.fbx",
    fbx_options={"Animation": False, "BakeAnimation": False}
)

# preset + partial override (v2)
result = api.export_fbx(
    slot=0,
    output_path=r"J:\output\char.fbx",
    preset="Unreal_Ani",
    fbx_options={"BakeAnimation": False}
)

if result['success']:
    print(f"Export complete: {result['output_path']}")
```

---