挣闲钱

Task

getAnswer

get answers

get all answers of questionareId by questionareId(通过任务id获取一个快递任务)


/task/answer/{questionareId}

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/answer/{questionareId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer questionareId = 56; // Integer | the id of questionare
        try {
            answers result = apiInstance.getAnswer(questionareId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#getAnswer");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer questionareId = 56; // Integer | the id of questionare
        try {
            answers result = apiInstance.getAnswer(questionareId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#getAnswer");
            e.printStackTrace();
        }
    }
}
Integer *questionareId = 56; // the id of questionare

TaskApi *apiInstance = [[TaskApi alloc] init];

// get answers
[apiInstance getAnswerWith:questionareId
              completionHandler: ^(answers output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var questionareId = 56; // {Integer} the id of questionare


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getAnswer(questionareId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getAnswerExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var questionareId = 56;  // Integer | the id of questionare

            try
            {
                // get answers
                answers result = apiInstance.getAnswer(questionareId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.getAnswer: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$questionareId = 56; // Integer | the id of questionare

try {
    $result = $api_instance->getAnswer($questionareId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->getAnswer: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $questionareId = 56; # Integer | the id of questionare

eval { 
    my $result = $api_instance->getAnswer(questionareId => $questionareId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->getAnswer: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
questionareId = 56 # Integer | the id of questionare

try: 
    # get answers
    api_response = api_instance.get_answer(questionareId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->getAnswer: %s\n" % e)

Parameters

Path parameters
Name Description
questionareId*
Integer
the id of questionare
Required

Responses

Status: 200 - success

Status: 404 - not found


getDelivery

get a deliveryTask

get a deliveryTask by taskId(通过任务id获取一个快递任务)


/task/delivery/{taskId}

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/delivery/{taskId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer taskId = 56; // Integer | the id of tasks
        try {
            deliveryTask result = apiInstance.getDelivery(taskId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#getDelivery");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer taskId = 56; // Integer | the id of tasks
        try {
            deliveryTask result = apiInstance.getDelivery(taskId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#getDelivery");
            e.printStackTrace();
        }
    }
}
Integer *taskId = 56; // the id of tasks

TaskApi *apiInstance = [[TaskApi alloc] init];

// get a deliveryTask
[apiInstance getDeliveryWith:taskId
              completionHandler: ^(deliveryTask output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var taskId = 56; // {Integer} the id of tasks


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getDelivery(taskId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getDeliveryExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var taskId = 56;  // Integer | the id of tasks

            try
            {
                // get a deliveryTask
                deliveryTask result = apiInstance.getDelivery(taskId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.getDelivery: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$taskId = 56; // Integer | the id of tasks

try {
    $result = $api_instance->getDelivery($taskId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->getDelivery: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $taskId = 56; # Integer | the id of tasks

eval { 
    my $result = $api_instance->getDelivery(taskId => $taskId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->getDelivery: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
taskId = 56 # Integer | the id of tasks

try: 
    # get a deliveryTask
    api_response = api_instance.get_delivery(taskId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->getDelivery: %s\n" % e)

Parameters

Path parameters
Name Description
taskId*
Integer
the id of tasks
Required

Responses

Status: 200 - success

Status: 404 - not found


getQuestionare

get a questionareTask

get a questionareTask by taskId(通过任务id获取一个问卷任务)


/task/questionare/{taskId}

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/questionare/{taskId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer taskId = 56; // Integer | the id of tasks
        try {
            questionareTask result = apiInstance.getQuestionare(taskId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#getQuestionare");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer taskId = 56; // Integer | the id of tasks
        try {
            questionareTask result = apiInstance.getQuestionare(taskId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#getQuestionare");
            e.printStackTrace();
        }
    }
}
Integer *taskId = 56; // the id of tasks

TaskApi *apiInstance = [[TaskApi alloc] init];

// get a questionareTask
[apiInstance getQuestionareWith:taskId
              completionHandler: ^(questionareTask output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var taskId = 56; // {Integer} the id of tasks


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getQuestionare(taskId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getQuestionareExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var taskId = 56;  // Integer | the id of tasks

            try
            {
                // get a questionareTask
                questionareTask result = apiInstance.getQuestionare(taskId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.getQuestionare: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$taskId = 56; // Integer | the id of tasks

try {
    $result = $api_instance->getQuestionare($taskId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->getQuestionare: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $taskId = 56; # Integer | the id of tasks

eval { 
    my $result = $api_instance->getQuestionare(taskId => $taskId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->getQuestionare: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
taskId = 56 # Integer | the id of tasks

try: 
    # get a questionareTask
    api_response = api_instance.get_questionare(taskId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->getQuestionare: %s\n" % e)

Parameters

Path parameters
Name Description
taskId*
Integer
the id of tasks
Required

Responses

Status: 200 - success

Status: 404 - not found


qAcceptPage

query accepted tasks

query a page of tasks accepted(获取一页用户接受的任务)


/task/accept

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/accept?page=&userId="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.qAcceptPage(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#qAcceptPage");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.qAcceptPage(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#qAcceptPage");
            e.printStackTrace();
        }
    }
}
Integer *page = 56; // if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Integer *userId = 56; // the id of user

TaskApi *apiInstance = [[TaskApi alloc] init];

// query accepted tasks
[apiInstance qAcceptPageWith:page
    userId:userId
              completionHandler: ^(tasks output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var page = 56; // {Integer} if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)

var userId = 56; // {Integer} the id of user


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.qAcceptPage(page, userId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class qAcceptPageExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var page = 56;  // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
            var userId = 56;  // Integer | the id of user

            try
            {
                // query accepted tasks
                tasks result = apiInstance.qAcceptPage(page, userId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.qAcceptPage: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
$userId = 56; // Integer | the id of user

try {
    $result = $api_instance->qAcceptPage($page, $userId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->qAcceptPage: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $page = 56; # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
my $userId = 56; # Integer | the id of user

eval { 
    my $result = $api_instance->qAcceptPage(page => $page, userId => $userId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->qAcceptPage: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
page = 56 # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
userId = 56 # Integer | the id of user

try: 
    # query accepted tasks
    api_response = api_instance.q_accept_page(page, userId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->qAcceptPage: %s\n" % e)

Parameters

Query parameters
Name Description
page*
Integer
if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Required
userId*
Integer
the id of user
Required

Responses

Status: 200 - success

Status: 404 - not found


qPublishPage

query published tasks

query a page of tasks published(获取一页用户发布的任务)


/task/publish

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/publish?page=&userId="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.qPublishPage(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#qPublishPage");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.qPublishPage(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#qPublishPage");
            e.printStackTrace();
        }
    }
}
Integer *page = 56; // if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Integer *userId = 56; // the id of user

TaskApi *apiInstance = [[TaskApi alloc] init];

// query published tasks
[apiInstance qPublishPageWith:page
    userId:userId
              completionHandler: ^(tasks output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var page = 56; // {Integer} if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)

var userId = 56; // {Integer} the id of user


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.qPublishPage(page, userId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class qPublishPageExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var page = 56;  // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
            var userId = 56;  // Integer | the id of user

            try
            {
                // query published tasks
                tasks result = apiInstance.qPublishPage(page, userId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.qPublishPage: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
$userId = 56; // Integer | the id of user

try {
    $result = $api_instance->qPublishPage($page, $userId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->qPublishPage: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $page = 56; # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
my $userId = 56; # Integer | the id of user

eval { 
    my $result = $api_instance->qPublishPage(page => $page, userId => $userId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->qPublishPage: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
page = 56 # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
userId = 56 # Integer | the id of user

try: 
    # query published tasks
    api_response = api_instance.q_publish_page(page, userId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->qPublishPage: %s\n" % e)

Parameters

Query parameters
Name Description
page*
Integer
if page is greater than 0, response a page of tasks(10), if page is 0, response 3 front tasks(如果page参数为0,则返回3个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Required
userId*
Integer
the id of user
Required

Responses

Status: 200 - success

Status: 404 - not found


queryPageD

query delivery tasks

query a page of delivery tasks not accepted and not published by user(获取一页用户没接受过,也不是由用户发布的快递任务)


/task/deliverys

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/deliverys?page=&userId="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.queryPageD(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#queryPageD");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.queryPageD(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#queryPageD");
            e.printStackTrace();
        }
    }
}
Integer *page = 56; // if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Integer *userId = 56; // the id of user

TaskApi *apiInstance = [[TaskApi alloc] init];

// query delivery tasks
[apiInstance queryPageDWith:page
    userId:userId
              completionHandler: ^(tasks output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var page = 56; // {Integer} if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)

var userId = 56; // {Integer} the id of user


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.queryPageD(page, userId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class queryPageDExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var page = 56;  // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
            var userId = 56;  // Integer | the id of user

            try
            {
                // query delivery tasks
                tasks result = apiInstance.queryPageD(page, userId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.queryPageD: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
$userId = 56; // Integer | the id of user

try {
    $result = $api_instance->queryPageD($page, $userId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->queryPageD: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $page = 56; # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
my $userId = 56; # Integer | the id of user

eval { 
    my $result = $api_instance->queryPageD(page => $page, userId => $userId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->queryPageD: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
page = 56 # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
userId = 56 # Integer | the id of user

try: 
    # query delivery tasks
    api_response = api_instance.query_page_d(page, userId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->queryPageD: %s\n" % e)

Parameters

Query parameters
Name Description
page*
Integer
if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Required
userId*
Integer
the id of user
Required

Responses

Status: 200 - success

Status: 404 - not found


queryPageQ

query questionare tasks

query a page of questionareTasks not accepted and not published by user(获取一页用户没接受过,也不是由用户发布的问卷任务)


/task/questionares

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/questionares?page=&userId="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.queryPageQ(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#queryPageQ");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.queryPageQ(page, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#queryPageQ");
            e.printStackTrace();
        }
    }
}
Integer *page = 56; // if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Integer *userId = 56; // the id of user

TaskApi *apiInstance = [[TaskApi alloc] init];

// query questionare tasks
[apiInstance queryPageQWith:page
    userId:userId
              completionHandler: ^(tasks output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var page = 56; // {Integer} if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)

var userId = 56; // {Integer} the id of user


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.queryPageQ(page, userId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class queryPageQExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var page = 56;  // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
            var userId = 56;  // Integer | the id of user

            try
            {
                // query questionare tasks
                tasks result = apiInstance.queryPageQ(page, userId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.queryPageQ: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$page = 56; // Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
$userId = 56; // Integer | the id of user

try {
    $result = $api_instance->queryPageQ($page, $userId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->queryPageQ: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $page = 56; # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
my $userId = 56; # Integer | the id of user

eval { 
    my $result = $api_instance->queryPageQ(page => $page, userId => $userId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->queryPageQ: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
page = 56 # Integer | if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
userId = 56 # Integer | the id of user

try: 
    # query questionare tasks
    api_response = api_instance.query_page_q(page, userId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->queryPageQ: %s\n" % e)

Parameters

Query parameters
Name Description
page*
Integer
if page is greater than 0, response a page of tasks(10), if page is 0, response 5 front tasks(如果page参数为0,则返回5个任务,供导航页使用;如果page大于0,则按页数返回10个任务)
Required
userId*
Integer
the id of user
Required

Responses

Status: 200 - success

Status: 404 - not found


queryTitle

query tasks by title

query some tasks not accepted and not published by user by title(通过标题查询获取用户没接受过,也不是由用户发布的任务)


/task/title

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/task/title?title=&userId="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskApi;

import java.io.File;
import java.util.*;

public class TaskApiExample {

    public static void main(String[] args) {
        
        TaskApi apiInstance = new TaskApi();
        Integer title = 56; // Integer | the title of tasks
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.queryTitle(title, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#queryTitle");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskApi;

public class TaskApiExample {

    public static void main(String[] args) {
        TaskApi apiInstance = new TaskApi();
        Integer title = 56; // Integer | the title of tasks
        Integer userId = 56; // Integer | the id of user
        try {
            tasks result = apiInstance.queryTitle(title, userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskApi#queryTitle");
            e.printStackTrace();
        }
    }
}
Integer *title = 56; // the title of tasks
Integer *userId = 56; // the id of user

TaskApi *apiInstance = [[TaskApi alloc] init];

// query tasks by title
[apiInstance queryTitleWith:title
    userId:userId
              completionHandler: ^(tasks output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.TaskApi()

var title = 56; // {Integer} the title of tasks

var userId = 56; // {Integer} the id of user


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.queryTitle(title, userId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class queryTitleExample
    {
        public void main()
        {
            
            var apiInstance = new TaskApi();
            var title = 56;  // Integer | the title of tasks
            var userId = 56;  // Integer | the id of user

            try
            {
                // query tasks by title
                tasks result = apiInstance.queryTitle(title, userId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskApi.queryTitle: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\TaskApi();
$title = 56; // Integer | the title of tasks
$userId = 56; // Integer | the id of user

try {
    $result = $api_instance->queryTitle($title, $userId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskApi->queryTitle: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskApi;

my $api_instance = WWW::SwaggerClient::TaskApi->new();
my $title = 56; # Integer | the title of tasks
my $userId = 56; # Integer | the id of user

eval { 
    my $result = $api_instance->queryTitle(title => $title, userId => $userId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskApi->queryTitle: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.TaskApi()
title = 56 # Integer | the title of tasks
userId = 56 # Integer | the id of user

try: 
    # query tasks by title
    api_response = api_instance.query_title(title, userId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskApi->queryTitle: %s\n" % e)

Parameters

Query parameters
Name Description
title*
Integer
the title of tasks
Required
userId*
Integer
the id of user
Required

Responses

Status: 200 - success

Status: 404 - not found


User

acceptTask

accept task

accept a new task(接受一个新任务,需要绑定用户和任务)


/user/task

Usage and SDK Samples

curl -X POST "https://petstore.swagger.io/user/task"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        UserAndTask body = ; // UserAndTask | the task that user accept(用户和接受的任务)
        try {
            userAndTask result = apiInstance.acceptTask(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#acceptTask");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        UserAndTask body = ; // UserAndTask | the task that user accept(用户和接受的任务)
        try {
            userAndTask result = apiInstance.acceptTask(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#acceptTask");
            e.printStackTrace();
        }
    }
}
UserAndTask *body = ; // the task that user accept(用户和接受的任务)

UserApi *apiInstance = [[UserApi alloc] init];

// accept task
[apiInstance acceptTaskWith:body
              completionHandler: ^(userAndTask output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {UserAndTask} the task that user accept(用户和接受的任务)


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.acceptTask(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class acceptTaskExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new UserAndTask(); // UserAndTask | the task that user accept(用户和接受的任务)

            try
            {
                // accept task
                userAndTask result = apiInstance.acceptTask(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.acceptTask: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // UserAndTask | the task that user accept(用户和接受的任务)

try {
    $result = $api_instance->acceptTask($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->acceptTask: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::UserAndTask->new(); # UserAndTask | the task that user accept(用户和接受的任务)

eval { 
    my $result = $api_instance->acceptTask(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->acceptTask: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # UserAndTask | the task that user accept(用户和接受的任务)

try: 
    # accept task
    api_response = api_instance.accept_task(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->acceptTask: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 201 - success

Status: 400 - bad request


fillQuery

fill out a questionare

fill out a questionare and post the answer(将用户填写的答案传输到后台)


/user/answer

Usage and SDK Samples

curl -X POST "https://petstore.swagger.io/user/answer"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        Answers body = ; // Answers | the answer should be posted
        try {
            answers result = apiInstance.fillQuery(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#fillQuery");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        Answers body = ; // Answers | the answer should be posted
        try {
            answers result = apiInstance.fillQuery(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#fillQuery");
            e.printStackTrace();
        }
    }
}
Answers *body = ; // the answer should be posted

UserApi *apiInstance = [[UserApi alloc] init];

// fill out a questionare
[apiInstance fillQueryWith:body
              completionHandler: ^(answers output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {Answers} the answer should be posted


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.fillQuery(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class fillQueryExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new Answers(); // Answers | the answer should be posted

            try
            {
                // fill out a questionare
                answers result = apiInstance.fillQuery(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.fillQuery: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // Answers | the answer should be posted

try {
    $result = $api_instance->fillQuery($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->fillQuery: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::Answers->new(); # Answers | the answer should be posted

eval { 
    my $result = $api_instance->fillQuery(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->fillQuery: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # Answers | the answer should be posted

try: 
    # fill out a questionare
    api_response = api_instance.fill_query(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->fillQuery: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 201 - create success

Status: 400 - bad request


finishAccept

finish task

finish a accepted task by userId and TaskId(通过用户id和任务id完成一个已接收的任务)


/user/accept

Usage and SDK Samples

curl -X PUT "https://petstore.swagger.io/user/accept"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        UserAndTask body = ; // UserAndTask | the task that user accept(用户和接受的任务)
        try {
            apiInstance.finishAccept(body);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#finishAccept");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        UserAndTask body = ; // UserAndTask | the task that user accept(用户和接受的任务)
        try {
            apiInstance.finishAccept(body);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#finishAccept");
            e.printStackTrace();
        }
    }
}
UserAndTask *body = ; // the task that user accept(用户和接受的任务)

UserApi *apiInstance = [[UserApi alloc] init];

// finish task
[apiInstance finishAcceptWith:body
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {UserAndTask} the task that user accept(用户和接受的任务)


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.finishAccept(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class finishAcceptExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new UserAndTask(); // UserAndTask | the task that user accept(用户和接受的任务)

            try
            {
                // finish task
                apiInstance.finishAccept(body);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.finishAccept: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // UserAndTask | the task that user accept(用户和接受的任务)

try {
    $api_instance->finishAccept($body);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->finishAccept: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::UserAndTask->new(); # UserAndTask | the task that user accept(用户和接受的任务)

eval { 
    $api_instance->finishAccept(body => $body);
};
if ($@) {
    warn "Exception when calling UserApi->finishAccept: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # UserAndTask | the task that user accept(用户和接受的任务)

try: 
    # finish task
    api_instance.finish_accept(body)
except ApiException as e:
    print("Exception when calling UserApi->finishAccept: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 204 - success

Status: 404 - not found


finishPublish

finish task

finish a published task(结束/取消一个已发布的任务)


/user/publish

Usage and SDK Samples

curl -X PUT "https://petstore.swagger.io/user/publish"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        Task body = ; // Task | the task
        try {
            apiInstance.finishPublish(body);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#finishPublish");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        Task body = ; // Task | the task
        try {
            apiInstance.finishPublish(body);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#finishPublish");
            e.printStackTrace();
        }
    }
}
Task *body = ; // the task

UserApi *apiInstance = [[UserApi alloc] init];

// finish task
[apiInstance finishPublishWith:body
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {Task} the task


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.finishPublish(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class finishPublishExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new Task(); // Task | the task

            try
            {
                // finish task
                apiInstance.finishPublish(body);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.finishPublish: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // Task | the task

try {
    $api_instance->finishPublish($body);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->finishPublish: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::Task->new(); # Task | the task

eval { 
    $api_instance->finishPublish(body => $body);
};
if ($@) {
    warn "Exception when calling UserApi->finishPublish: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # Task | the task

try: 
    # finish task
    api_instance.finish_publish(body)
except ApiException as e:
    print("Exception when calling UserApi->finishPublish: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 204 - success

Status: 404 - not found


getUser

get user by userId


/user/{userId}

Usage and SDK Samples

curl -X GET "https://petstore.swagger.io/user/{userId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        Integer userId = 56; // Integer | 
        try {
            user result = apiInstance.getUser(userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#getUser");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        Integer userId = 56; // Integer | 
        try {
            user result = apiInstance.getUser(userId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#getUser");
            e.printStackTrace();
        }
    }
}
Integer *userId = 56; // 

UserApi *apiInstance = [[UserApi alloc] init];

// get user by userId
[apiInstance getUserWith:userId
              completionHandler: ^(user output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var userId = 56; // {Integer} 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.getUser(userId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class getUserExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var userId = 56;  // Integer | 

            try
            {
                // get user by userId
                user result = apiInstance.getUser(userId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.getUser: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$userId = 56; // Integer | 

try {
    $result = $api_instance->getUser($userId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->getUser: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $userId = 56; # Integer | 

eval { 
    my $result = $api_instance->getUser(userId => $userId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->getUser: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
userId = 56 # Integer | 

try: 
    # get user by userId
    api_response = api_instance.get_user(userId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->getUser: %s\n" % e)

Parameters

Path parameters
Name Description
userId*
Integer
Required

Responses

Status: 200 - success

Status: 404 - not found


publishDTask

publish deliveryTask

publish a new deliveryTask(发布一个新的快递任务,需要填写表单)


/user/delivery

Usage and SDK Samples

curl -X POST "https://petstore.swagger.io/user/delivery"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        DeliveryTask body = ; // DeliveryTask | Task form information should be posted(任务表单)
        try {
            deliveryTask result = apiInstance.publishDTask(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#publishDTask");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        DeliveryTask body = ; // DeliveryTask | Task form information should be posted(任务表单)
        try {
            deliveryTask result = apiInstance.publishDTask(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#publishDTask");
            e.printStackTrace();
        }
    }
}
DeliveryTask *body = ; // Task form information should be posted(任务表单)

UserApi *apiInstance = [[UserApi alloc] init];

// publish deliveryTask
[apiInstance publishDTaskWith:body
              completionHandler: ^(deliveryTask output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {DeliveryTask} Task form information should be posted(任务表单)


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.publishDTask(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class publishDTaskExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new DeliveryTask(); // DeliveryTask | Task form information should be posted(任务表单)

            try
            {
                // publish deliveryTask
                deliveryTask result = apiInstance.publishDTask(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.publishDTask: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // DeliveryTask | Task form information should be posted(任务表单)

try {
    $result = $api_instance->publishDTask($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->publishDTask: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::DeliveryTask->new(); # DeliveryTask | Task form information should be posted(任务表单)

eval { 
    my $result = $api_instance->publishDTask(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->publishDTask: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # DeliveryTask | Task form information should be posted(任务表单)

try: 
    # publish deliveryTask
    api_response = api_instance.publish_d_task(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->publishDTask: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 201 - create success

Status: 400 - bad request


publishQTask

publish questionareTask

publish a new questionareTask(发布一个新的问卷任务,需要填写表单)


/user/questionare

Usage and SDK Samples

curl -X POST "https://petstore.swagger.io/user/questionare"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        QuestionareTask body = ; // QuestionareTask | Task form information should be posted(任务表单)
        try {
            questionareTask result = apiInstance.publishQTask(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#publishQTask");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        QuestionareTask body = ; // QuestionareTask | Task form information should be posted(任务表单)
        try {
            questionareTask result = apiInstance.publishQTask(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#publishQTask");
            e.printStackTrace();
        }
    }
}
QuestionareTask *body = ; // Task form information should be posted(任务表单)

UserApi *apiInstance = [[UserApi alloc] init];

// publish questionareTask
[apiInstance publishQTaskWith:body
              completionHandler: ^(questionareTask output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {QuestionareTask} Task form information should be posted(任务表单)


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.publishQTask(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class publishQTaskExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new QuestionareTask(); // QuestionareTask | Task form information should be posted(任务表单)

            try
            {
                // publish questionareTask
                questionareTask result = apiInstance.publishQTask(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.publishQTask: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // QuestionareTask | Task form information should be posted(任务表单)

try {
    $result = $api_instance->publishQTask($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->publishQTask: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::QuestionareTask->new(); # QuestionareTask | Task form information should be posted(任务表单)

eval { 
    my $result = $api_instance->publishQTask(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->publishQTask: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # QuestionareTask | Task form information should be posted(任务表单)

try: 
    # publish questionareTask
    api_response = api_instance.publish_q_task(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->publishQTask: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 201 - create success

Status: 400 - bad request


signIn

sign in


/user/signin

Usage and SDK Samples

curl -X POST "https://petstore.swagger.io/user/signin"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        User body = ; // User | User form information should be posted, include userId and password
        try {
            inline_response_200 result = apiInstance.signIn(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#signIn");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        User body = ; // User | User form information should be posted, include userId and password
        try {
            inline_response_200 result = apiInstance.signIn(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#signIn");
            e.printStackTrace();
        }
    }
}
User *body = ; // User form information should be posted, include userId and password

UserApi *apiInstance = [[UserApi alloc] init];

// sign in
[apiInstance signInWith:body
              completionHandler: ^(inline_response_200 output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {User} User form information should be posted, include userId and password


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.signIn(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class signInExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new User(); // User | User form information should be posted, include userId and password

            try
            {
                // sign in
                inline_response_200 result = apiInstance.signIn(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.signIn: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // User | User form information should be posted, include userId and password

try {
    $result = $api_instance->signIn($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->signIn: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::User->new(); # User | User form information should be posted, include userId and password

eval { 
    my $result = $api_instance->signIn(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->signIn: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # User | User form information should be posted, include userId and password

try: 
    # sign in
    api_response = api_instance.sign_in(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->signIn: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 200 - success

Status: 400 - bad request


signOut

sign out


/user/signout

Usage and SDK Samples

curl -X DELETE "https://petstore.swagger.io/user/signout"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        try {
            apiInstance.signOut();
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#signOut");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        try {
            apiInstance.signOut();
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#signOut");
            e.printStackTrace();
        }
    }
}

UserApi *apiInstance = [[UserApi alloc] init];

// sign out
[apiInstance signOutWithCompletionHandler: 
              ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.signOut(callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class signOutExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();

            try
            {
                // sign out
                apiInstance.signOut();
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.signOut: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();

try {
    $api_instance->signOut();
} catch (Exception $e) {
    echo 'Exception when calling UserApi->signOut: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();

eval { 
    $api_instance->signOut();
};
if ($@) {
    warn "Exception when calling UserApi->signOut: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()

try: 
    # sign out
    api_instance.sign_out()
except ApiException as e:
    print("Exception when calling UserApi->signOut: %s\n" % e)

Parameters

Responses

Status: 200 - success

Status: 400 - bad request


signUp

sign up


/user/signup

Usage and SDK Samples

curl -X POST "https://petstore.swagger.io/user/signup"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserApi;

import java.io.File;
import java.util.*;

public class UserApiExample {

    public static void main(String[] args) {
        
        UserApi apiInstance = new UserApi();
        User body = ; // User | User form information should be posted
        try {
            user result = apiInstance.signUp(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#signUp");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserApi;

public class UserApiExample {

    public static void main(String[] args) {
        UserApi apiInstance = new UserApi();
        User body = ; // User | User form information should be posted
        try {
            user result = apiInstance.signUp(body);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserApi#signUp");
            e.printStackTrace();
        }
    }
}
User *body = ; // User form information should be posted

UserApi *apiInstance = [[UserApi alloc] init];

// sign up
[apiInstance signUpWith:body
              completionHandler: ^(user output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var SwaggerJsClient = require('swagger-js-client');

var api = new SwaggerJsClient.UserApi()

var body = ; // {User} User form information should be posted


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.signUp(body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class signUpExample
    {
        public void main()
        {
            
            var apiInstance = new UserApi();
            var body = new User(); // User | User form information should be posted

            try
            {
                // sign up
                user result = apiInstance.signUp(body);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserApi.signUp: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Swagger\Client\Api\UserApi();
$body = ; // User | User form information should be posted

try {
    $result = $api_instance->signUp($body);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserApi->signUp: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserApi;

my $api_instance = WWW::SwaggerClient::UserApi->new();
my $body = WWW::SwaggerClient::Object::User->new(); # User | User form information should be posted

eval { 
    my $result = $api_instance->signUp(body => $body);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserApi->signUp: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = swagger_client.UserApi()
body =  # User | User form information should be posted

try: 
    # sign up
    api_response = api_instance.sign_up(body)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserApi->signUp: %s\n" % e)

Parameters

Body parameters
Name Description
body *

Responses

Status: 201 - create success

Status: 400 - bad request