lib/client/board/src/api/DevelopersApi.js

83 lines
2.5 KiB
JavaScript

/**
* board
* Taxnexus Onboarding Service
*
* The version of the OpenAPI document: 0.0.2
* Contact: noc@taxnexus.net
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*
*/
import ApiClient from "../ApiClient";
import Developer from '../model/Developer';
import Error from '../model/Error';
import RuleExecution from '../model/RuleExecution';
/**
* Developers service.
* @module api/DevelopersApi
* @version 0.0.2
*/
export default class DevelopersApi {
/**
* Constructs a new DevelopersApi.
* @alias module:api/DevelopersApi
* @class
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
* default to {@link module:ApiClient#instance} if unspecified.
*/
constructor(apiClient) {
this.apiClient = apiClient || ApiClient.instance;
}
/**
* Callback function to receive the result of the postDevelopers operation.
* @callback module:api/DevelopersApi~postDevelopersCallback
* @param {String} error Error message, if any.
* @param {module:model/RuleExecution} data The data returned by the service call.
* @param {String} response The complete HTTP response.
*/
/**
* Onboard new developer
* Register new developers with POST
* @param {module:model/Developer} developerRequest A single Developer struct for onboarding
* @param {module:api/DevelopersApi~postDevelopersCallback} callback The callback function, accepting three arguments: error, data, response
* data is of type: {@link module:model/RuleExecution}
*/
postDevelopers(developerRequest, callback) {
let postBody = developerRequest;
// verify the required parameter 'developerRequest' is set
if (developerRequest === undefined || developerRequest === null) {
throw new Error("Missing the required parameter 'developerRequest' when calling postDevelopers");
}
let pathParams = {
};
let queryParams = {
};
let headerParams = {
};
let formParams = {
};
let authNames = ['ApiKeyAuth'];
let contentTypes = ['application/json'];
let accepts = ['application/json'];
let returnType = RuleExecution;
return this.apiClient.callApi(
'/developers', 'POST',
pathParams, queryParams, headerParams, formParams, postBody,
authNames, contentTypes, accepts, returnType, null, callback
);
}
}