Godot SDK Setup
Get the Quest Data SDK running in your Godot 4 game in 5 minutes. The plugin installs as an AutoLoad singleton and requires no manual initialization.
Prerequisites
Section titled “Prerequisites”- Godot 4.x (4.0 or higher)
- Quest Data Account (free tier available)
- Game API Key (from dashboard)
- Network: Internet connection (SDK batches events every 10s)
Installation
Section titled “Installation”Step 1: Download the Plugin
Section titled “Step 1: Download the Plugin”- Go to questdata.io/download
- Download
quest-data-godot-plugin.zip - Extract to your Godot project folder
Your structure should look like:
MyGame/├── addons/│ └── quest_data/│ ├── plugin.gd│ ├── quest_data.gd│ └── ...├── scenes/└── project.godotStep 2: Enable the Plugin
Section titled “Step 2: Enable the Plugin”- Open Godot and load your project
- Go to Project > Project Settings > Plugins tab
- Search for “Quest Data”
- Enable the checkbox
- Restart Godot
Step 3: Configure API Credentials
Section titled “Step 3: Configure API Credentials”- Go to Project > Project Settings > Quest Data tab (new tab appears after restart)
- Fill in:
- API Key: Your game’s API key (from dashboard)
- API URL:
https://api.questdata.io(default)
- Click Save
# Check that settings are validprint(ProjectSettings.get_setting("quest_data/api_key"))# Output: qd_sk_a1b2c3d4e5...First Event
Section titled “First Event”Test the setup by tracking your first event:
# In any scriptfunc _ready(): QuestData.track("game_start", { "version": "1.0.0", "platform": OS.get_name() })
# Check dashboard: Live Feed should show your event within 10 secondsThe SDK will:
- Queue the event in memory
- Batch with other events (max 10 events per batch)
- Send batch after 10 seconds or when 10+ events queued
- Retry on network failure
Common Configuration
Section titled “Common Configuration”Disable on Dev/Debug
Section titled “Disable on Dev/Debug”You probably don’t want to track events during testing:
# In a config file or autoloadconst QUEST_DATA_ENABLED = OS.get_unique_id() != "dev_machine_id"
func _ready(): if QUEST_DATA_ENABLED: QuestData.track("game_start") else: print("Quest Data disabled for dev")Custom Session ID
Section titled “Custom Session ID”By default, the SDK generates a random session ID. Override it:
QuestData.set_session_id("my_custom_session_id")
# Do this before first track() callTroubleshooting
Section titled “Troubleshooting”Plugin Not Loading
Section titled “Plugin Not Loading”Symptom: QuestData.track() returns error “Undefined identifier”
Solutions:
- Verify plugin is enabled: Project > Project Settings > Plugins
- Check that
addons/quest_data/plugin.gdexists - Restart Godot completely
- Check console for errors: View > Toggle Console
Events Not Appearing
Section titled “Events Not Appearing”Symptom: Track events, but dashboard shows no data
Solutions:
- Check API key is correct:
ProjectSettings.get_setting("quest_data/api_key") - Verify API URL ends without trailing slash:
https://api.questdata.io - Check network connection (SDK logs to console on error)
- Wait 15 seconds (SDK batches events every 10s + server latency)
- Go to Configuration > Logs in dashboard to see API errors
Offline Fallback Not Working
Section titled “Offline Fallback Not Working”Symptom: Game crashes when network is disconnected
Solutions:
- SDK handles offline gracefully by default
- Check that
user://directory is writable - Verify events are queued:
QuestData.get_queue_size()
Next Steps
Section titled “Next Steps”- Event Tracking — All event types and custom events
- Progression — Level tracking with automatic duration
- Error Tracking — Crashes with stack traces
- Purchase Tracking — Revenue and IAP
- Remote Config & Game Data — Feature flags and balance tables
- Remote Logging — Debug logs sent to dashboard