{"uid":"cap_XUGyEQyiAfhIdQ4gtom7m","slug":"chainhilt-hyperliquid-user-abstraction-preview-4b90bce2","name":"Chainhilt Hyperliquid User Abstraction Preview","description":"Prepare a user-signed abstraction change: disabled, unifiedAccount, or portfolioMargin. Sign with the owner's wallet and submit to the returned submitPath. Errors: 400 invalid input; execution may return 422 rejection or 502 provider failure. Treat spot and perp as one balance only when the account abstraction mode is \"unifiedAccount\".","url":"https://chainhilt.ai/api/v1/perp/hyperliquid/user-abstraction/preview?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"user":{"type":"string","pattern":"^0x[a-fA-F0-9]{40}$","description":"Account whose mode changes; the account owner's wallet signs."},"nonce":{"type":"integer","minimum":0,"description":"Action nonce in milliseconds since the epoch; defaults to the current time."},"abstraction":{"enum":["disabled","unifiedAccount","portfolioMargin"],"type":"string","description":"New mode: \"disabled\", \"unifiedAccount\" (spot and perp as one balance) or \"portfolioMargin\"."}}},"responseSchema":{"type":"json","example":{"response":{"errors":[],"actions":[{"data":{"nonce":1710000000000,"action":{"type":"userSetAbstraction","user":"0x1111111111111111111111111111111111111111","nonce":1710000000000,"abstraction":"unifiedAccount","hyperliquidChain":"Mainnet","signatureChainId":"0xa4b1"},"typedData":{"types":{"EIP712Domain":[{"name":"name","type":"string"},{"name":"version","type":"string"},{"name":"chainId","type":"uint256"},{"name":"verifyingContract","type":"address"}],"HyperliquidTransaction:UserSetAbstraction":[{"name":"hyperliquidChain","type":"string"},{"name":"user","type":"address"},{"name":"abstraction","type":"string"},{"name":"nonce","type":"uint64"}]},"domain":{"name":"HyperliquidSignTransaction","chainId":42161,"version":"1","verifyingContract":"0x0000000000000000000000000000000000000000"},"message":{"type":"userSetAbstraction","user":"0x1111111111111111111111111111111111111111","nonce":1710000000000,"abstraction":"unifiedAccount","hyperliquidChain":"Mainnet","signatureChainId":"0xa4b1"},"primaryType":"HyperliquidTransaction:UserSetAbstraction"}},"type":"signature","chainId":42161,"protocol":"hyperliquid","submitPath":"/perp/hyperliquid/user-abstraction/execute"}],"warnings":[]}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_SZXORFxhfOChhoXD-pntm","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Prepares an EIP-712 typed-data payload for changing a Hyperliquid account's abstraction mode (disabled, unifiedAccount, or portfolioMargin) that the account owner must sign before submitting.","exampleAgentPrompt":"Prepare the EIP-712 signing payload to switch my Hyperliquid account 0x1111111111111111111111111111111111111111 to unifiedAccount abstraction mode using nonce 1710000000000, so I can sign and submit it.","exampleUseCases":[{"title":"Enable unified spot and perp balance","prompt":"I want to combine my spot and perp balances into one on Hyperliquid — generate the signing payload to switch my account 0xAbCd...1234 to unifiedAccount mode with nonce 1710000000001 so I can sign it with my wallet."},{"title":"Switch to portfolio margin mode","prompt":"Prepare the EIP-712 transaction data to change my Hyperliquid account 0xDeAdBeEf...5678 to portfolioMargin abstraction using nonce 1710050000000, then tell me where to submit it after I sign."},{"title":"Disable account abstraction entirely","prompt":"I need to turn off account abstraction on my Hyperliquid account 0x2222222222222222222222222222222222222222 — can you build the typed data payload with nonce 1710100000000 so I can sign it and disable the unified mode?"}],"resultDescription":"Returns an action object containing the full EIP-712 typed-data structure (domain, types, message, primaryType), the nonce, chainId (42161 Arbitrum), the protocol tag 'hyperliquid', and a submitPath (/perp/hyperliquid/user-abstraction/execute) to use after signing. Any validation errors or warnings are included in the response envelope.","failureModes":["Invalid or malformed user address (not a valid 0x EVM address) returns 400","Nonce out of valid range (negative or exceeding MAX_SAFE_INTEGER) returns 400","Invalid abstraction enum value (not disabled/unifiedAccount/portfolioMargin) returns 400","Network or upstream Hyperliquid connectivity issues may cause 5xx responses","Missing required fields returns validation error"],"whenToPreferThis":"Use this endpoint when you need to change a Hyperliquid account's abstraction mode (unified balance, portfolio margin, or disabled) and require the EIP-712 payload for user signing before submission. Prefer this over direct on-chain construction when you want a pre-validated, correctly formatted typed-data object ready for wallet signing, with the submit path included.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-16T18:35:44.541Z","isFirstParty":false,"canonicalSlug":"chainhilt-hyperliquid-user-abstraction-preview-4b90bce2"}