Repository navigation
Conversation
Adds list_musedin_jobs, join_musedin, verify_on_musedin (1 USDC on Base over x402, via @x402/fetch with the wallet provider's signer) and apply_to_musedin_job. Base mainnet only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
🟡 Heimdall Review Status
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds a
musedinaction provider to@coinbase/agentkit. MusedIn is a job network for AI agents. With this provider an AgentKit agent can find open jobs, join, verify its wallet and apply, using its own wallet for the one paid step.Actions:
list_musedin_jobs:GET https://musedin.com/api/roles(optional?skill=). Returns each open job's title, slug, skills, pay (when set), budget (when paid), done line and link (https://musedin.com/jobs/<slug>). No account needed.join_musedin:POST https://musedin.com/api/quickstartwith{ name, headline, skills?, src: "agentkit" }. Returns the agent id and a bearer token (shown once). The token is kept in the provider instance's memory for the actions below and returned to the agent; it is never logged. A second call while a token is set returns the current agent instead of creating another.verify_on_musedin:POST https://musedin.com/api/verifywith{ wallet }(the wallet provider's address), paid over x402: 1 USDC on Base, once. Verified agents get the first 24 h on paid jobs and rank first in job alerts. Payment uses@x402/fetchwrapFetchWithPaymentand@x402/evmregisterExactEvmSchemewith the same wallet-provider signer the x402 action provider builds. The client is restricted: it only reacheshttps://musedin.com, and a policy accepts only USDC on Base (eip155:8453) at the 1 USDC verify price. A pending settlement (409 with retry-after) tells the agent not to pay again and where to check status.apply_to_musedin_job:POST https://musedin.com/api/applywith{ role, note? }and the bearer token. MusedIn errors (did_you_mean,suggestions,retry) are passed back so the agent can correct itself.Config:
musedinActionProvider({ apiToken }), orMUSEDIN_API_TOKEN, to reuse an agent from an earlier join. Neither is required.Network support: Base mainnet only (
supportsNetwork). MusedIn takes verification payments on Base mainnet, not Base Sepolia.API reference: https://musedin.com/muse.txt (sections 10, 11, 14, 27).
Tests
Unit tests in
typescript/agentkit/src/action-providers/musedin/musedinActionProvider.test.ts(fetch and the x402 client mocked): config and env token, network support, job listing and skill filter, join request body and in-memory token, no duplicate join, name-taken suggestions, apply with bearer token, unknown slug, verify payment through the wrapped fetch, payment policy (only 1 USDC on Base), host restriction, pending settlement, refused payment.Manual chatbot run: not done yet; happy to add one with a funded Base wallet if reviewers want it.
Checklist
A couple of things to include in your PR for completeness: