Skip to main content
This guide explains how wallet providers can integrate with the Vincent API to display and manage user app installations. By following this flow, wallet providers can show users their installed Vincent apps and the associated smart account addresses.

Integration Flow Overview

API Endpoints

1. Fetch App Information

Before installing an app, fetch its details to display to the user. Endpoint: GET /app/:appId
{
  "appId": 123,
  "name": "DCA Trading Bot",
  "description": "Automated dollar-cost averaging for your portfolio",
  "contactEmail": "[email protected]",
  "appUrl": "https://example.com/app",
  "logo": "https://example.com/logo.png",
  "activeVersion": 1,
  "manager": "0x1234...5678"
}

2. Initiate App Installation

Start the installation process by providing the user’s wallet address. Endpoint: POST /user/:appId/install-app
{
  "userControllerAddress": "0xUserWalletAddress..."
}

3. Complete Installation with Signature

Have the user sign the typed data and submit it to complete the installation. Endpoint: POST /user/:appId/complete-installation
{
  "typedDataSignature": "0xSignature...",
  "appInstallationDataToSign": { ... }
}

4. Retrieve Agent Account Address

After installation (or on subsequent visits), retrieve the user’s agent smart account address for a specific app. Endpoint: POST /user/:appId/agent-account
{
  "userControllerAddress": "0xUserWalletAddress..."
}

Smart Account Index Derivation

Each app installation creates a unique smart account address derived from the user’s wallet address and the app ID. This ensures:
  • Deterministic addresses: The same user + app combination always produces the same agent address
  • App isolation: Each app gets its own dedicated smart account
  • Consistent lookup: Wallet providers can reliably query agent addresses
The index is derived using: keccak256("vincent_app_id_{appId}") To derive the address client-side (for verification):
import { getKernelAddressFromECDSA } from '@zerodev/ecdsa-validator';
import { constants } from '@zerodev/sdk';
import { deriveSmartAccountIndex } from '@lit-protocol/vincent-contracts-sdk';

const agentAddress = await getKernelAddressFromECDSA({
  publicClient,
  eoaAddress: userWalletAddress,
  index: deriveSmartAccountIndex(appId),
  entryPoint: constants.getEntryPoint('0.7'),
  kernelVersion: constants.KERNEL_V3_1,
});