Skip to main content
PATCH
/
v2
/
wallets
/
{id}
/
strategy
Update wallet strategy
curl --request PATCH \
  --url https://sandbox.groundtech.co/v2/wallets/{id}/strategy \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "requestId": "c3d4e5f6-0000-4000-8000-000000000001",
  "allocations": [
    {
      "yieldSourceId": "syrup-usdc",
      "pct": 40
    },
    {
      "yieldSourceId": "morpho-gauntlet-usdc",
      "pct": 30
    },
    {
      "yieldSourceId": "morpho-steakhouse-usdc",
      "pct": 30
    }
  ]
}
'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "label": "<string>",
  "createdAt": "2023-11-07T05:31:56Z",
  "depositAddresses": {
    "arbitrum": "0xAbC1230000000000000000000000000000000001",
    "base": "0xAbC1230000000000000000000000000000000001",
    "ethereum": "0xAbC1230000000000000000000000000000000001",
    "polygon": "0xAbC1230000000000000000000000000000000001",
    "solana": "7vFgKxM3bP4oEFbqkPmA5E2rYJ8HqKz8abc1"
  },
  "balance": {
    "totalUsd": "<string>",
    "withdrawableUsd": "<string>",
    "availableToInitiateUsd": "<string>",
    "pendingWithdrawalUsd": "<string>",
    "inTransitUsd": "<string>",
    "earnedUsd": "<string>"
  },
  "positions": [
    {
      "yieldSourceId": "<string>",
      "type": "cash",
      "name": "<string>",
      "valueUsd": "<string>",
      "pct": 123
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string<uuid>
required

Wallet ID

Body

application/json
requestId
string<uuid>
required

Client-generated idempotency key (UUID v4).

allocations
object[]
required

New strategy allocations; pct values must sum to 100.

Response

Strategy updated successfully

id
string<uuid>
label
string | null
createdAt
string<date-time>
depositAddresses
object

Deposit addresses keyed by chain name.

Example:
{
  "arbitrum": "0xAbC1230000000000000000000000000000000001",
  "base": "0xAbC1230000000000000000000000000000000001",
  "ethereum": "0xAbC1230000000000000000000000000000000001",
  "polygon": "0xAbC1230000000000000000000000000000000001",
  "solana": "7vFgKxM3bP4oEFbqkPmA5E2rYJ8HqKz8abc1"
}
balance
object
positions
object[]