Newer
Older
drafter-groovy / src / main / groovy / io / swagger / api / JobsApi.groovy
package io.swagger.api;

import groovyx.net.http.*
import static groovyx.net.http.ContentType.*
import static groovyx.net.http.Method.*
import io.swagger.api.ApiUtils

import io.swagger.model.FinishedJob

import java.util.*;

@Mixin(ApiUtils)
class JobsApi {
    String basePath = "https://localhost/v1"
    String versionPath = "/api/v1"

    def statusFinishedJobsJobidGet ( String jobid, Closure onSuccess, Closure onFailure)  {
        // create path and map path parameters (TODO)
        String resourcePath = "/status/finished-jobs/{jobid}"

        // query params
        def queryParams = [:]
        def headerParams = [:]
    
        // verify required params are set
        if (jobid == null) {
            throw new RuntimeException("missing required params jobid")
        }

        

        // Also still TODO: form params, body param

        invokeApi(onSuccess, onFailure, basePath, versionPath, resourcePath, queryParams, headerParams,
                    "GET", "",
                    FinishedJob.class )
                    
    }
    def statusWritesLockedGet ( Closure onSuccess, Closure onFailure)  {
        // create path and map path parameters (TODO)
        String resourcePath = "/status/writes-locked"

        // query params
        def queryParams = [:]
        def headerParams = [:]
    

        

        // Also still TODO: form params, body param

        invokeApi(onSuccess, onFailure, basePath, versionPath, resourcePath, queryParams, headerParams,
                    "GET", "",
                    Boolean.class )
                    
    }
}