Skip to content

Latest commit

 

History

History
526 lines (392 loc) · 13.6 KB

TasksApi.md

File metadata and controls

526 lines (392 loc) · 13.6 KB

TasksApi

All URIs are relative to http://localhost

Method HTTP request Description
tasksCreateTask POST /api/tasks/v1/Tasks Create a new task
tasksDeleteTask DELETE /api/tasks/v1/Tasks/{taskId} Delete a task from a storage
tasksGet GET /api/tasks/v1/Tasks/{taskId} Get a task by a specified id
tasksGetList GET /api/tasks/v1/Tasks Get tasks list
tasksGetPermissions GET /api/tasks/v1/Tasks/{id}/permissions Get all Task permissions
tasksRenameTask PUT /api/tasks/v1/Tasks/{taskId}/rename Rename a task
tasksRunTask POST /api/tasks/v1/Tasks/run Run a task from request body
tasksRunTaskById POST /api/tasks/v1/Tasks/{taskId}/run Run a task by id
tasksUpdatePermissions POST /api/tasks/v1/Tasks/{id}/permissions Update permissions
tasksUpdateTask PUT /api/tasks/v1/Tasks/{taskId} Update a task

tasksCreateTask

TaskBaseVM tasksCreateTask(createTaskBaseVM)

Create a new task

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val createTaskBaseVM : CreateTaskBaseVM =  // CreateTaskBaseVM | task's view model. You have to specify task type (type: \"ExportTemplate\")
try {
    val result : TaskBaseVM = apiInstance.tasksCreateTask(createTaskBaseVM)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksCreateTask")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksCreateTask")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
createTaskBaseVM CreateTaskBaseVM task's view model. You have to specify task type (type: "ExportTemplate") [optional]

Return type

TaskBaseVM

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

tasksDeleteTask

tasksDeleteTask(taskId)

Delete a task from a storage

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val taskId : kotlin.String = taskId_example // kotlin.String | deleting task id
try {
    apiInstance.tasksDeleteTask(taskId)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksDeleteTask")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksDeleteTask")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
taskId kotlin.String deleting task id

Return type

null (empty response body)

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

tasksGet

TaskBaseVM tasksGet(taskId)

Get a task by a specified id

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val taskId : kotlin.String = taskId_example // kotlin.String | a task id
try {
    val result : TaskBaseVM = apiInstance.tasksGet(taskId)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksGet")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksGet")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
taskId kotlin.String a task id

Return type

TaskBaseVM

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

tasksGetList

TasksVM tasksGetList(skip, take, subscriptionId, searchPattern)

Get tasks list

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val skip : kotlin.Int = 56 // kotlin.Int | number of tasks, that have to be skipped
val take : kotlin.Int = 56 // kotlin.Int | number of tasks, that have to be returned
val subscriptionId : kotlin.String = subscriptionId_example // kotlin.String | subscription id
val searchPattern : kotlin.String = searchPattern_example // kotlin.String | 
try {
    val result : TasksVM = apiInstance.tasksGetList(skip, take, subscriptionId, searchPattern)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksGetList")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksGetList")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
skip kotlin.Int number of tasks, that have to be skipped [optional] [default to 0]
take kotlin.Int number of tasks, that have to be returned [optional] [default to 10]
subscriptionId kotlin.String subscription id [optional]
searchPattern kotlin.String [optional] [default to ""]

Return type

TasksVM

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

tasksGetPermissions

TaskPermissionsVM tasksGetPermissions(id)

Get all Task permissions

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val id : kotlin.String = id_example // kotlin.String | task id
try {
    val result : TaskPermissionsVM = apiInstance.tasksGetPermissions(id)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksGetPermissions")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksGetPermissions")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
id kotlin.String task id

Return type

TaskPermissionsVM

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

tasksRenameTask

TaskBaseVM tasksRenameTask(taskId, newName)

Rename a task

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val taskId : kotlin.String = taskId_example // kotlin.String | renaming task id
val newName : kotlin.String = newName_example // kotlin.String | task's new Name
try {
    val result : TaskBaseVM = apiInstance.tasksRenameTask(taskId, newName)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksRenameTask")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksRenameTask")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
taskId kotlin.String renaming task id
newName kotlin.String task's new Name [optional]

Return type

TaskBaseVM

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

tasksRunTask

tasksRunTask(runTaskBaseVM)

Run a task from request body

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val runTaskBaseVM : RunTaskBaseVM =  // RunTaskBaseVM | task's view model
try {
    apiInstance.tasksRunTask(runTaskBaseVM)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksRunTask")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksRunTask")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
runTaskBaseVM RunTaskBaseVM task's view model [optional]

Return type

null (empty response body)

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

tasksRunTaskById

tasksRunTaskById(taskId)

Run a task by id

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val taskId : kotlin.String = taskId_example // kotlin.String | task id
try {
    apiInstance.tasksRunTaskById(taskId)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksRunTaskById")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksRunTaskById")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
taskId kotlin.String task id

Return type

null (empty response body)

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

tasksUpdatePermissions

tasksUpdatePermissions(id, updateTaskPermissionsVM)

Update permissions

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val id : kotlin.String = id_example // kotlin.String | task id
val updateTaskPermissionsVM : UpdateTaskPermissionsVM =  // UpdateTaskPermissionsVM | new permissions
try {
    apiInstance.tasksUpdatePermissions(id, updateTaskPermissionsVM)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksUpdatePermissions")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksUpdatePermissions")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
id kotlin.String task id
updateTaskPermissionsVM UpdateTaskPermissionsVM new permissions [optional]

Return type

null (empty response body)

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

tasksUpdateTask

TaskBaseVM tasksUpdateTask(taskId, updateTaskBaseVM)

Update a task

Example

// Import classes:
//import org.openapitools.client.infrastructure.*
//import cloud.fastreport.model.*

val apiInstance = TasksApi()
val taskId : kotlin.String = taskId_example // kotlin.String | updating task id
val updateTaskBaseVM : UpdateTaskBaseVM =  // UpdateTaskBaseVM | task's view model. You have to specify task type (type: \"ExportTemplate\")
try {
    val result : TaskBaseVM = apiInstance.tasksUpdateTask(taskId, updateTaskBaseVM)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling TasksApi#tasksUpdateTask")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling TasksApi#tasksUpdateTask")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
taskId kotlin.String updating task id
updateTaskBaseVM UpdateTaskBaseVM task's view model. You have to specify task type (type: "ExportTemplate") [optional]

Return type

TaskBaseVM

Authorization

Configure ApiKey: ApiClient.username = "" ApiClient.password = "" Configure JWT: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json