Prerequisites
- A VictoriaMetrics query address that CloudThinker can reach over HTTPS: single-node VictoriaMetrics, a cluster’s vmselect, or a VictoriaMetrics Cloud access endpoint. For a private address, follow Reaching private services.
- A bearer token, unless the endpoint needs no authentication.
- A CloudThinker workspace where you can add connections.
Setup
Create the credential
- VictoriaMetrics Cloud: open your deployment, go to the Access tokens tab, and click Generate Token. Name it
cloudthinker, choose the Read access level, and click Generate. Copy the secret from the Key column, and copy the access endpoint from the same tab. See VictoriaMetrics Cloud access tokens. - vmauth: ask your operator to add a user with a
bearer_tokenwhose routes allow the query API. See vmauth.
Find the query address
/api/v1:- Single-node:
https://vm.example.com. - Cluster: the vmselect path for your tenant, such as
https://vmselect.example.com/select/0/prometheus. See the cluster URL format. - VictoriaMetrics Cloud: the access endpoint from the previous step.
Connect in CloudThinker
VictoriaMetrics connected; the query API answered. CloudThinker then opens a chat that takes a read-only deep look at the connection (“Often takes about 15 min. You can leave the chat.”). To run it again later, open the card’s More menu and choose Try in chat.Connection details
Required permissions
Agent capabilities
Verify the connection
Example prompts
Troubleshooting
VictoriaMetrics rejected the saved credentials.
VictoriaMetrics rejected the saved credentials.
The credentials signed in, but they cannot run queries on that address.
The credentials signed in, but they cannot run queries on that address.
That address did not accept a query. For a cluster, use the vmselect path such as /select/0/prometheus.
That address did not accept a query. For a cluster, use the vmselect path such as /select/0/prometheus.
/select/<accountID>/prometheus to Query URL.That address has no query API. Check the URL and any path such as /select/0/prometheus.
That address has no query API. Check the URL and any path such as /select/0/prometheus.
/api/v1/query under that address. Check the host and path. Enter the address without /api/v1.VictoriaMetrics answered with a redirect. Use the exact query address, including any path such as /select/0/prometheus.
VictoriaMetrics answered with a redirect. Use the exact query address, including any path such as /select/0/prometheus.
The VictoriaMetrics certificate is not trusted.
The VictoriaMetrics certificate is not trusted.
BEGIN and END lines.Could not reach VictoriaMetrics over HTTPS. Check the URL and that the sandbox can reach it.
Could not reach VictoriaMetrics over HTTPS. Check the URL and that the sandbox can reach it.
https:// and that your firewall lets CloudThinker reach VictoriaMetrics. Browser access from your laptop alone is not enough.Alerts are missing or the alerts section fails
Alerts are missing or the alerts section fails
-vmalert.proxyURL, or read alerts in vmalert.A snapshot fails with HTTP 404
A snapshot fails with HTTP 404
An agent says the VictoriaMetrics write tool is off
An agent says the VictoriaMetrics write tool is off
Security
- Least privilege — grant only the permissions the agents need for your use case; start read-only and widen later.
- Read-only by default — use read-only credentials unless you want agents to make changes through this connection.
- Rotate credentials — rotate keys and tokens on your normal schedule; CloudThinker picks up the new value when you update the connection.
- Revoke on offboarding — remove the credential at the provider when you delete a connection or a teammate leaves.
- Read the snapshot name before you approve a delete. A deleted snapshot can’t be restored.