-
Notifications
You must be signed in to change notification settings - Fork 0
FAQ & Troubleshooting
This section covers common questions and issues you might encounter while using the CoinQuant PHP SDK [1].
No. The health check (/health) and community endpoints (leaderboards, public backtests) work anonymously without a token. All other endpoints require a valid service-account token.
This is expected behavior. The CoinQuant AI decides the most appropriate response shape based on your prompt. Always branch your application logic on $result->type rather than assuming a specific response format.
Service account tokens last for 30 days. When a token expires, the API will return a 401 Unauthorized status. You must generate a new key in the CoinQuant web app under Settings → Service Accounts.
Yes. The CoinQuantClient is a plain PHP class with no framework dependencies. The Laravel service provider and facade are completely optional and only load if you are using the framework.
Yes. You can pass your own pre-configured Guzzle client to the CoinQuantClient constructor. This allows you to set custom timeouts, configure proxies, or attach middleware for automatic retries.
This means the backtest is still running and has not reached a terminal state.
-
Solution: Use the
createBacktestAndWait()helper method, which polls the status automatically. Alternatively, keep callinggetBacktest()until the status changes tocompleted,failed, orerrorbefore requesting the results.
This indicates you have run out of API credits.
-
Solution: Top up your credits on the CoinQuant platform. You can programmatically check your balance using
$client->getCredits().
This usually happens if Composer's autoloader isn't included.
-
Solution: Ensure you have
require __DIR__ . '/vendor/autoload.php';at the top of your script. If you are using Laravel, ensure you rancomposer require tigusigalpa/coinquant-php.
If you encounter an issue not listed here, or suspect an API bug:
- Catch the
CoinQuantException. - Extract the Request ID using
$e->getRequestId(). - Provide this Request ID when contacting CoinQuant support, as it allows them to trace the exact execution of your call.