mirror of
https://github.com/hanzo-kt/sdk.git
synced 2026-10-30 20:43:57 +00:00
Coroutine-native client covering the full Hanzo /v1 cloud surface, for JVM and Android. Generated with openapi-generator kotlin (library=jvm-okhttp4, useCoroutines=true). Coordinate: ai.hanzo:sdk. Base URL: https://api.hanzo.ai. Co-authored-by: Hanzo Dev <[email protected]>
6.2 KiB
6.2 KiB
TodosApi
All URIs are relative to https://api.hanzo.ai
| Method | HTTP request | Description |
|---|---|---|
| autoListTodos | GET /v1/auto/todos | List todos |
| flowGetTodo | GET /v1/flow/todos/{id} | Get a todo |
| flowListTodoActivities | GET /v1/flow/todo-activities | List todo activity log |
| flowListTodos | GET /v1/flow/todos | List todos |
| flowUpdateTodo | POST /v1/flow/todos/{id} | Update a todo |
autoListTodos
kotlin.Any autoListTodos()
List todos
Example
// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*
val apiInstance = TodosApi()
try {
val result : kotlin.Any = apiInstance.autoListTodos()
println(result)
} catch (e: ClientException) {
println("4xx response calling TodosApi#autoListTodos")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling TodosApi#autoListTodos")
e.printStackTrace()
}
Parameters
This endpoint does not need any parameter.
Return type
Authorization
Configure bearerAuth statically:
ApiClient.accessToken = ""
Configure bearerAuth dynamically:
apiInstance.accessTokenProvider = { "" }
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
flowGetTodo
kotlin.Any flowGetTodo(id)
Get a todo
Example
// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*
val apiInstance = TodosApi()
val id : kotlin.String = id_example // kotlin.String |
try {
val result : kotlin.Any = apiInstance.flowGetTodo(id)
println(result)
} catch (e: ClientException) {
println("4xx response calling TodosApi#flowGetTodo")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling TodosApi#flowGetTodo")
e.printStackTrace()
}
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| id | kotlin.String |
Return type
Authorization
Configure bearerAuth statically:
ApiClient.accessToken = ""
Configure bearerAuth dynamically:
apiInstance.accessTokenProvider = { "" }
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
flowListTodoActivities
kotlin.Any flowListTodoActivities(todoId)
List todo activity log
Example
// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*
val apiInstance = TodosApi()
val todoId : kotlin.String = todoId_example // kotlin.String |
try {
val result : kotlin.Any = apiInstance.flowListTodoActivities(todoId)
println(result)
} catch (e: ClientException) {
println("4xx response calling TodosApi#flowListTodoActivities")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling TodosApi#flowListTodoActivities")
e.printStackTrace()
}
Parameters
| Name | Type | Description | Notes |
|---|---|---|---|
| todoId | kotlin.String |
Return type
Authorization
Configure bearerAuth statically:
ApiClient.accessToken = ""
Configure bearerAuth dynamically:
apiInstance.accessTokenProvider = { "" }
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
flowListTodos
kotlin.Any flowListTodos(cursor, limit)
List todos
Example
// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*
val apiInstance = TodosApi()
val cursor : kotlin.String = cursor_example // kotlin.String |
val limit : kotlin.Int = 56 // kotlin.Int |
try {
val result : kotlin.Any = apiInstance.flowListTodos(cursor, limit)
println(result)
} catch (e: ClientException) {
println("4xx response calling TodosApi#flowListTodos")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling TodosApi#flowListTodos")
e.printStackTrace()
}
Parameters
| cursor | kotlin.String| | [optional] |
| Name | Type | Description | Notes |
|---|---|---|---|
| limit | kotlin.Int | [optional] |
Return type
Authorization
Configure bearerAuth statically:
ApiClient.accessToken = ""
Configure bearerAuth dynamically:
apiInstance.accessTokenProvider = { "" }
HTTP request headers
- Content-Type: Not defined
- Accept: application/json
flowUpdateTodo
kotlin.Any flowUpdateTodo(id, flowUpdateTodoRequest)
Update a todo
Example
// Import classes:
//import ai.hanzo.sdk.infrastructure.*
//import ai.hanzo.sdk.models.*
val apiInstance = TodosApi()
val id : kotlin.String = id_example // kotlin.String |
val flowUpdateTodoRequest : FlowUpdateTodoRequest = // FlowUpdateTodoRequest |
try {
val result : kotlin.Any = apiInstance.flowUpdateTodo(id, flowUpdateTodoRequest)
println(result)
} catch (e: ClientException) {
println("4xx response calling TodosApi#flowUpdateTodo")
e.printStackTrace()
} catch (e: ServerException) {
println("5xx response calling TodosApi#flowUpdateTodo")
e.printStackTrace()
}
Parameters
| id | kotlin.String| | |
| Name | Type | Description | Notes |
|---|---|---|---|
| flowUpdateTodoRequest | FlowUpdateTodoRequest |
Return type
Authorization
Configure bearerAuth statically:
ApiClient.accessToken = ""
Configure bearerAuth dynamically:
apiInstance.accessTokenProvider = { "" }
HTTP request headers
- Content-Type: application/json
- Accept: application/json