// Copyright 2019 getensh.com. All rights reserved.
// Use of this source code is governed by getensh.com.
package param_v1_0

import (
	"gd_management_gateway/params/param_base"
	"gd_management_gateway/rpc_apis/gd_management"
)

type ManagementTryBaseApiReq struct {
	param_base.BasicParam
	ApiInfo gd_management.ManagementTryBaseApiReq `json:"api_info" in:"body"`
}

type ManagementTryBaseApiResp struct {
	param_base.SimpleResp
	Data    string `json:"data"`
	OrderNo string `json:"order_no,omitempty"`
}

type ManagementCreateTryApiTaskReq struct {
	param_base.BasicParam
	ApiName         string `json:"api_name" in:"query"`
	Router          string `json:"router" in:"query"`
	Method          string `json:"method" in:"query"`
	AppKey          string `json:"app_key" in:"query"`
	AppSecret       string `json:"app_secret" in:"query"`
	AppPassword     string `json:"app_password" in:"query"`
	IsCrypto        bool   `json:"is_crypto" in:"query"`
	MerchantAccount bool   `json:"merchant_account" in:"query"`
	MultiNumber     int    `json:"multi_number" in:"query"`
	TaskName        string `json:"task_name" in:"query"`
	EnglishHeader   bool   `json:"chinese_header" in:"query"`
	EncryptoType    int `json:"encrypto_type"`
}

type ManagementCreateTryApiTaskResp struct {
	param_base.SimpleResp
}

type ManagementDeleteTryApiTaskReq struct {
	param_base.BasicParam
	TaskId int64 `json:"task_id" in:"query" require:"true"`
}

type ManagementDeleteTryApiTaskResp struct {
	param_base.SimpleResp
}

type ManagementGetTryApiTaskListReq struct {
	param_base.BasicParam
	IsAll      bool   `json:"is_all" in:"query"`
	PageNumber int    `json:"page_number" in:"query"`
	PageSize   int    `json:"page_size" in:"query"`
	ApiName    string `json:"api_name" in:"query" require:"false"`
	Type       int    `json:"type" in:"query" require:"true"`
}

type ManagementGetTryApiTaskListResp struct {
	param_base.SimpleResp
	Data gd_management.ManagementGetTryApiTaskListReply `json:"data"`
}

type ManagementUploadApiTaskReq struct {
}

type ManagementUploadApiTaskResp struct {
	param_base.SimpleResp
	FileName string `json:"file_name"`
}

type ManagementTryApiExcelReq struct {
	param_base.BasicParam
}

type ManagementTryApiExcelResp struct {
	param_base.SimpleResp
	FileName string `json:"file_name"`
}

type ManagementChangeApiTaskBody struct {
	TaskId        int64 `json:"task_id" in:"path"`
	StatusCode    int   `json:"status"`
	EnglishHeader bool  `json:"english_header"`
}
type ManagementChangeApiTaskStateReq struct {
	param_base.BasicParam
	Data ManagementChangeApiTaskBody `json:"data" in:"body"`
}

type ManagementChangeApiTaskStateResp struct {
	param_base.SimpleResp
}
