> ## Documentation Index
> Fetch the complete documentation index at: https://perps-api.vooi.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Build EIP-712 data the main Hyperliquid wallet must sign to change the abstraction mode



## OpenAPI

````yaml https://vooi-api-app.fly.dev/swagger/json post /exchange/hyperliquid/set-abstraction/prepare
openapi: 3.1.0
info:
  title: VOOI API
  description: Unified perps API
  version: '1.0'
  contact: {}
servers:
  - url: https://perps-api.vooi.io
security: []
tags: []
paths:
  /exchange/hyperliquid/set-abstraction/prepare:
    post:
      tags:
        - Exchange / Hyperliquid
      summary: >-
        Build EIP-712 data the main Hyperliquid wallet must sign to change the
        abstraction mode
      operationId: HyperliquidController_prepareSetAbstraction
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PrepareHyperliquidSetAbstractionBodyDto'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/PrepareHyperliquidSetAbstractionResponseDto
      security:
        - bearer: []
components:
  schemas:
    PrepareHyperliquidSetAbstractionBodyDto:
      type: object
      properties:
        abstractionMode:
          type: string
          enum:
            - disabled
            - unifiedAccount
            - portfolioMargin
            - dexAbstraction
          description: >-
            Target Hyperliquid account abstraction mode to set: disabled
            (perps-only), unifiedAccount and portfolioMargin (spot+perp unified
            collateral), or dexAbstraction.
      required:
        - abstractionMode
      title: PrepareHyperliquidSetAbstractionBody
    PrepareHyperliquidSetAbstractionResponseDto:
      type: object
      properties:
        pendingData:
          type: object
          properties:
            action:
              type: object
              propertyNames:
                type: string
              additionalProperties:
                $ref: '#/components/schemas/Json'
              description: >-
                Hyperliquid userSetAbstraction action to be replayed in execute
                step.
            nonce:
              type: number
              description: Nonce (timestamp in ms) used for replay protection.
          required:
            - action
            - nonce
          description: Opaque payload to pass back to the execute endpoint.
        signData:
          type: object
          properties:
            domain:
              type: object
              properties:
                chainId:
                  type: number
                name:
                  type: string
                verifyingContract:
                  type: string
                  description: Ethereum address
                  example: '0x1234567890abcdef1234567890abcdef12345678'
                version:
                  type: string
              required:
                - name
                - version
            message:
              type: object
              propertyNames:
                type: string
              additionalProperties: {}
            primaryType:
              type: string
            types:
              type: object
              propertyNames:
                type: string
              additionalProperties:
                type: array
                items:
                  type: object
                  properties:
                    name:
                      type: string
                    type:
                      type: string
                  required:
                    - name
                    - type
          required:
            - domain
            - message
            - primaryType
            - types
          description: EIP-712 typed data to sign with the main wallet
      required:
        - pendingData
        - signData
      title: PrepareHyperliquidSetAbstractionResponse
    Json:
      description: Any JSON value
      title: Json
      anyOf:
        - type: string
        - type: number
        - type: boolean
        - type: 'null'
        - type: array
          items:
            $ref: '#/components/schemas/Json'
        - type: object
          propertyNames:
            type: string
          additionalProperties:
            $ref: '#/components/schemas/Json'
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.