OneinchApi

OneinchApi

All URIs are relative to https://moon-vault-api-git-ew-supabase-migration-moonup.vercel.app

Method
HTTP request
Description

POST /oneinch/approve-call-data

POST /oneinch/approve-spender

POST /oneinch/protocols

POST /oneinch/quote

POST /oneinch/{accountName}/swap

POST /oneinch/tokens

approveCallData

kotlin.Any approveCallData(body)

Example

// Import classes:
//import org.usemoonai.moonsdk.infrastructure.*
//import org.usemoonai.moonsdk.models.*

val apiInstance = OneinchApi()
val body : kotlin.Any =  // kotlin.Any | 
try {
    val result : kotlin.Any = apiInstance.approveCallData(body)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling OneinchApi#approveCallData")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling OneinchApi#approveCallData")
    e.printStackTrace()
}

Parameters

Name
Type
Description
Notes

body

kotlin.Any

Return type

kotlin.Any

Authorization

Configure ApiKeyAuth: ApiClient.apiKey["x-api-key"] = "" ApiClient.apiKeyPrefix["x-api-key"] = "" Configure BearerAuth: ApiClient.apiKey["Authorization"] = "" ApiClient.apiKeyPrefix["Authorization"] = ""

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

approveSpender

kotlin.Any approveSpender(body)

Example

// Import classes:
//import org.usemoonai.moonsdk.infrastructure.*
//import org.usemoonai.moonsdk.models.*

val apiInstance = OneinchApi()
val body : kotlin.Any =  // kotlin.Any | 
try {
    val result : kotlin.Any = apiInstance.approveSpender(body)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling OneinchApi#approveSpender")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling OneinchApi#approveSpender")
    e.printStackTrace()
}

Parameters

Name
Type
Description
Notes

body

kotlin.Any

Return type

kotlin.Any

Authorization

Configure ApiKeyAuth: ApiClient.apiKey["x-api-key"] = "" ApiClient.apiKeyPrefix["x-api-key"] = "" Configure BearerAuth: ApiClient.apiKey["Authorization"] = "" ApiClient.apiKeyPrefix["Authorization"] = ""

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

protocols

kotlin.Any protocols(body)

Example

// Import classes:
//import org.usemoonai.moonsdk.infrastructure.*
//import org.usemoonai.moonsdk.models.*

val apiInstance = OneinchApi()
val body : kotlin.Any =  // kotlin.Any | 
try {
    val result : kotlin.Any = apiInstance.protocols(body)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling OneinchApi#protocols")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling OneinchApi#protocols")
    e.printStackTrace()
}

Parameters

Name
Type
Description
Notes

body

kotlin.Any

Return type

kotlin.Any

Authorization

Configure ApiKeyAuth: ApiClient.apiKey["x-api-key"] = "" ApiClient.apiKeyPrefix["x-api-key"] = "" Configure BearerAuth: ApiClient.apiKey["Authorization"] = "" ApiClient.apiKeyPrefix["Authorization"] = ""

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

quote

kotlin.Any quote(body)

Example

// Import classes:
//import org.usemoonai.moonsdk.infrastructure.*
//import org.usemoonai.moonsdk.models.*

val apiInstance = OneinchApi()
val body : kotlin.Any =  // kotlin.Any | 
try {
    val result : kotlin.Any = apiInstance.quote(body)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling OneinchApi#quote")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling OneinchApi#quote")
    e.printStackTrace()
}

Parameters

Name
Type
Description
Notes

body

kotlin.Any

Return type

kotlin.Any

Authorization

Configure ApiKeyAuth: ApiClient.apiKey["x-api-key"] = "" ApiClient.apiKeyPrefix["x-api-key"] = "" Configure BearerAuth: ApiClient.apiKey["Authorization"] = "" ApiClient.apiKeyPrefix["Authorization"] = ""

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

swap

kotlin.Any swap(accountName, authorization, getSwapDto)

Example

// Import classes:
//import org.usemoonai.moonsdk.infrastructure.*
//import org.usemoonai.moonsdk.models.*

val apiInstance = OneinchApi()
val accountName : kotlin.String = accountName_example // kotlin.String | 
val authorization : kotlin.String = authorization_example // kotlin.String | 
val getSwapDto : GetSwapDto =  // GetSwapDto | 
try {
    val result : kotlin.Any = apiInstance.swap(accountName, authorization, getSwapDto)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling OneinchApi#swap")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling OneinchApi#swap")
    e.printStackTrace()
}

Parameters

Name
Type
Description
Notes

accountName

kotlin.String

authorization

kotlin.String

getSwapDto

Return type

kotlin.Any

Authorization

Configure ApiKeyAuth: ApiClient.apiKey["x-api-key"] = "" ApiClient.apiKeyPrefix["x-api-key"] = "" Configure BearerAuth: ApiClient.apiKey["Authorization"] = "" ApiClient.apiKeyPrefix["Authorization"] = ""

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

tokens

kotlin.Any tokens(body)

Example

// Import classes:
//import org.usemoonai.moonsdk.infrastructure.*
//import org.usemoonai.moonsdk.models.*

val apiInstance = OneinchApi()
val body : kotlin.Any =  // kotlin.Any | 
try {
    val result : kotlin.Any = apiInstance.tokens(body)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling OneinchApi#tokens")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling OneinchApi#tokens")
    e.printStackTrace()
}

Parameters

Name
Type
Description
Notes

body

kotlin.Any

Return type

kotlin.Any

Authorization

Configure ApiKeyAuth: ApiClient.apiKey["x-api-key"] = "" ApiClient.apiKeyPrefix["x-api-key"] = "" Configure BearerAuth: ApiClient.apiKey["Authorization"] = "" ApiClient.apiKeyPrefix["Authorization"] = ""

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

Last updated