Connect Kaggle to your Wiro AI agent
Find datasets, competitions and notebooks on Kaggle and read your notebooks' output.
Did last night's run of the Kestrel churn notebook finish? I need its validation score.
Yes, the latest run of kestrel-churn-baseline is complete. It wrote submission.csv, metrics.json and feature_importance.csv, and the log ends with the model saved. From metrics.json:
- Validation AUC 0.871
- Log loss 0.312
- Best iteration 418 of 2,000, stopped early
Overview
What Kaggle does for your agent
The agent works as the Kaggle account behind the username and API token, and what it creates stays private unless asked otherwise. It searches public datasets and competitions, writes and runs notebooks on CPU, GPU or TPU, reads each run's status, output files and log, uploads datasets and new versions, and submits files or notebook versions to competitions. Joining a competition and accepting its rules happen on Kaggle's website, since the API cannot do that step.
Use cases
What your Wiro agent can do with Kaggle
Find a dataset to start a forecasting project
Ask for public Kaggle datasets on retail sales or energy demand. The agent lists matches with their size, downloads, votes and usability score, opens the ones you like to show their files and sizes, and suggests which one to build on and why.
Write and run a baseline notebook, then read the results
Describe what you want to predict and the dataset to use. The agent writes a Python script, saves it as a private Kaggle notebook on CPU and starts the run. Later it checks the status, reads the output CSV and the end of the log, and reports the score or the error Kaggle gave.
Re-run a reporting notebook every night
To automate Kaggle reporting, keep a notebook that rebuilds a report from fresh data. A Scheduled Task saves a new version of it each night, which runs it on Kaggle, and a second Scheduled Task in the morning reads the output file and posts the key figures in Chat, or Kaggle's error message if the run failed.
Daily leaderboard check for a competition you entered
A Scheduled Task reads the top of the competition's public leaderboard and your own submissions each day, then posts the leading scores next to your recent public scores, so the team sees where it stands without opening Kaggle.
Publish a cleaned file as a private Kaggle dataset
Point the agent at a CSV at a public link, or paste the data, and it creates a private Kaggle dataset and checks that processing finished. When next month's file arrives, it uploads a new version that carries every file the dataset should keep.
Submit to a competition once you approve the file
When a notebook's predictions are ready, the agent can send the output file, or a notebook version for a code competition, as a submission. Submitting asks for your approval in Chat by default, which matters because each one uses one of the day's submissions, and the agent reads the score once Kaggle has graded it.
How it works
How Kaggle works with Wiro
- 01
Connect Kaggle
Deploy an agent, open its Connectors tab, choose Kaggle and paste what the Connect dialog asks for.
- 02
Choose what each action may do
Set each Kaggle action to Allow, Ask or Block, in Chat and in Scheduled Tasks. By default, read-only actions run, and the rest ask first in Chat.
- 03
Ask in Chat or schedule it
Ask your agent for Kaggle work in Chat, or put it on a Scheduled Task that runs on its own.
- Where it runsInside your agent. Its requests go straight from the agent to Kaggle.
- Where its data goes
www.kaggle.comstorage.googleapis.comwww.googleapis.com - How it signs inPaste a key. It is stored encrypted and never shown again.
What it can do
Actions your Wiro agent can take in Kaggle
By default, read-only actions run, and the rest ask first in Chat and run in Scheduled Tasks. Each agent can set any action to Allow, Ask or Block.
Read-only 13 actions
Looks things up in Kaggle and changes nothing.
| Action | What it does | Chat | Scheduled Tasks |
|---|---|---|---|
| Get my Kaggle GPU and TPU quota | The weekly GPU and TPU allowance of the account, in hours: used, held by running sessions, left, the weekly total, and when it refreshes. | Allow | Allow |
| List Kaggle notebooks | Your own notebooks, last run first by default, with their ref, link, language, type, visibility, accelerator, internet, votes and current version; or someone's public notebooks with scope everyone and user. | Allow | Allow |
| Get a Kaggle notebook and its code | One notebook's settings and its code: the script, or the whole notebook JSON, in windows of about 24 KB. | Allow | Allow |
| Get a Kaggle notebook run's status | The status of the notebook's latest run: queued, running, complete, error, or cancelled, with Kaggle's failure message on error. | Allow | Allow |
| Get a Kaggle notebook's output and log | The output files of the notebook's latest run (names and signed download links that expire soon) and the last lines of its log. | Allow | Allow |
| Read a Kaggle notebook output file | Shows a text output file of the notebook's latest run (a CSV of results, a log, a JSON file), in windows of about 24 KB. | Allow | Allow |
| List Kaggle datasets | Your own datasets, last updated first by default, with ref, link, size, visibility, downloads, votes, version and usability; or public datasets (scope public, with search) or one user's (user). | Allow | Allow |
| List a Kaggle dataset's files | The files of a dataset (its current version, or a given one), with their names, sizes and dates. | Allow | Allow |
| Get a Kaggle dataset's status | Whether a dataset (after a create or a new version) is still processing or ready. | Allow | Allow |
| List Kaggle competitions | Competitions matching some words, latest deadline first by default, with category, reward, deadline, teams, whether you entered and whether it takes notebook submissions only. | Allow | Allow |
| Get a Kaggle competition leaderboard | The top of a competition's public leaderboard: rank, team, score and submission date. | Allow | Allow |
| List my Kaggle competition submissions | Your submissions to a competition, newest first, with file, date, status, public and private scores and description. | Allow | Allow |
| Read other Kaggle data | Reads what the actions above do not cover, straight from the Kaggle API. | Allow | Allow |
Create and send 4 actions
Creates or sends something new in Kaggle, such as a post, a message or an email.
| Action | What it does | Chat | Scheduled Tasks |
|---|---|---|---|
| Push a Kaggle notebook | Creates a notebook, or saves a new version of an existing one. | Ask | Allow |
| Create a Kaggle dataset | Creates a dataset from files given by public https URL or as text: each file is uploaded to the signed address Kaggle hands out, then the dataset is created, private unless asked. | Ask | Allow |
| Submit a file to a Kaggle competition | Sends a submission file (from a public https URL or as text) to a competition: Kaggle hands out an upload address, the file goes there, then the submission is made. | Ask | Allow |
| Submit a notebook version to a Kaggle competition | For a code competition: submits a version of one of your notebooks and the output file it writes. | Ask | Allow |
Change and delete 2 actions
Changes or deletes what is already in Kaggle.
| Action | What it does | Chat | Scheduled Tasks |
|---|---|---|---|
| Upload a new Kaggle dataset version | Uploads a new version of a dataset. | Ask | Allow |
| Make other Kaggle changes | Sends any other change straight to the Kaggle API. | Ask | Allow |
How to connect
Connect Kaggle to Wiro
Open the agent's Connectors tab, choose Kaggle and paste what it asks for. Values are stored encrypted and never shown again.
What the Connect dialog asks for
| Field | About |
|---|---|
| Kaggle UsernameRequired | Notebooks, datasets and competitions on your own Kaggle account. The agent saves what it creates as private, and makes nothing public and sends no competition submission without your approval.
The agent names your notebooks and datasets with it ( |
| Kaggle API TokenRequired | A Kaggle API token lets the agent use the Kaggle API as you.
Use a token from Generate New Token. The older key from Create Legacy API Key (the 32-character The Kaggle API is free. What the agent runs uses your own Kaggle allowances: a weekly GPU and TPU quota (the agent checks what is left before it turns a GPU on), up to 12 hours per notebook run (9 hours on TPU), 200 GB per dataset and 200 GB of private datasets in all. Kaggle asks for a phone-verified account before a notebook can use a GPU or the internet. Kaggle limits request rates on its own: when it answers "Too many requests", the agent waits and tries again later. To revoke the token, go back to Settings, API on Kaggle and remove it there. The agent stops reaching Kaggle until you save a new token here. |
Troubleshooting
Troubleshooting Kaggle
What to check when Kaggle stops working for your agent.
- An invalid or expired key If Kaggle refuses the key, for example after it was deleted or expired, the agent's Kaggle actions fail. Create a new key in Kaggle, then open the agent's Connectors tab, choose Kaggle and paste it in place of the old one.
- Limits set by Kaggle Kaggle limits how much an account can do, such as how many requests it takes in a minute. An action over a limit fails until the limit resets: wait and ask again, or check your Kaggle plan.
For developers
Connect Kaggle from your own product
Every call is a POST to the Wiro API with your project's API key. On a sign-in, your customers see your own app's name.
- 01
Read the connector
Detail answers without a session: what the connector needs and the tools it gives an agent.
POST /AgentConnector/Detail { "slug": "kaggle" }Response { "result": true, "errors": [], "agentconnectors": [ { "slug": "kaggle", "title": "Kaggle", "category": "data", "authtype": "fields", "credentialfields": [ { "name": "username", "label": "Kaggle Username", "required": true, "secret": false, "format": "text" }, { "name": "apitoken", "label": "Kaggle API Token", "required": true, "secret": true, "format": "password" } ], "tools": [ { "name": "get_quota", "readonly": true }, { "name": "list_notebooks", "readonly": true } ] } ] } - 02
Connect with the values
Send what the person typed in your form. A value you leave out keeps what the connection holds; an empty one clears it.
POST /UserAgent/ConnectorConnect { "useragentguid": "YOUR_AGENT_GUID", "slug": "kaggle", "values": { "username": "YOUR_USERNAME", "apitoken": "YOUR_SECRET" } }Response { "result": true, "errors": [], "status": "connected", "applied": 1, "restart": "scheduled" } - 03
Read the status
connected, pending (a sign-in not finished), reauth (sign in again) or error. Values and tokens never come back.
POST /UserAgent/ConnectorList { "useragentguid": "YOUR_AGENT_GUID" }Response { "result": true, "errors": [], "useragentconnectors": [ { "slug": "kaggle", "title": "Kaggle", "authtype": "fields", "status": "connected", "accounts": {}, "savedvariables": [ "apitoken", "username" ], "lasterror": null } ] } - 04
Disconnect
Revokes a sign-in where the vendor allows it, deletes what the connection holds and removes the connector from the running agent.
POST /UserAgent/ConnectorDisconnect { "useragentguid": "YOUR_AGENT_GUID", "slug": "kaggle" }Response { "result": true, "errors": [], "removed": true, "revoked": false, "restart": "scheduled" }
Questions
Kaggle and Wiro FAQ
What can a Kaggle AI agent do with my account?
It searches public datasets, competitions and notebooks, and lists your own. It reads a notebook's code, creates or updates your notebooks and runs them, then reads each run's status, output files and log. It can create private datasets and add new versions, read leaderboards and your submissions, submit a file or a notebook version to a competition you joined, and make other Kaggle API calls. Deleting notebooks, datasets or models is not offered.
How do I connect Kaggle to an AI agent?
It takes two values. Your username is the last part of your Kaggle profile address. For the token, open Settings on Kaggle, go to the API section, click Generate New Token and copy it: it starts with KGAT_ and is 37 characters long. Choose Kaggle on the agent's Connectors tab and paste both, or ask the agent in Chat to add Kaggle. An older legacy API key is refused, so use a newly generated token.
What do I need on my Kaggle account first?
A Kaggle account is enough for datasets, notebooks on CPU and reading competitions. Kaggle asks for a phone-verified account before a notebook can use a GPU or reach the internet. To submit to a competition, join it and accept its rules on Kaggle's website first, because the Kaggle API cannot do that step.
Will the agent run Kaggle notebooks or submit entries without asking me?
In Chat, creating or running a notebook, creating a dataset or a new version, submitting to a competition and sending other changes through the Kaggle API ask for your approval by default, while a Scheduled Task runs them unless you change their setting to Ask or Block. Each action has its own Allow, Ask or Block setting for Chat and for Scheduled Tasks, and reading runs without asking. What the agent creates stays private unless you ask for it to be public.
Can the agent use a GPU or TPU on Kaggle?
Yes, when you ask for one. It can run a notebook on two T4 GPUs, an L4 GPU or a TPU v5e-8, and it checks how many of the week's GPU and TPU hours are left before it turns one on. Without such a request it runs on CPU with the internet off. Kaggle stops a run after 12 hours, or 9 hours on TPU.
Where is my Kaggle API token kept?
The token is kept encrypted and out of the AI model's view. Your username is saved with it, since the agent names your notebooks and datasets with it. To revoke access, remove the token under Settings, API on Kaggle: the agent stops reaching Kaggle until you save a new token on the Connectors tab.
What does the Kaggle MCP connector cost?
The connector costs nothing extra on any agent plan, and the Kaggle API is free. What the agent runs uses your own Kaggle allowances: the weekly GPU and TPU quota, 200 GB per dataset and 200 GB of private datasets in all. Kaggle also limits request rates; when it answers that there are too many requests, the agent waits and tries again later.
Access
Revoke Kaggle access
Disconnect it on the agent's Connectors tab at any time; the keys or sign-in it holds are deleted.
Related connectors
More data connectors for your Wiro agent
Put Kaggle to work with Wiro
Deploy an agent and connect Kaggle from its Connectors tab. Every agent plan includes it: Starter $5, Pro $30 and Max $100 a month.