UNPKG

@matech/thebigpos-sdk

Version:
1,051 lines 170 kB
/* eslint-disable */ /* tslint:disable */ // @ts-nocheck /* * --------------------------------------------------------------- * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## * ## ## * ## AUTHOR: acacode ## * ## SOURCE: https://github.com/acacode/swagger-typescript-api ## * --------------------------------------------------------------- */ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } return new (P || (P = Promise))(function (resolve, reject) { function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } step((generator = generator.apply(thisArg, _arguments || [])).next()); }); }; var __rest = (this && this.__rest) || function (s, e) { var t = {}; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p]; if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]]; } return t; }; import axios from "axios"; export var ContentType; (function (ContentType) { ContentType["Json"] = "application/json"; ContentType["JsonApi"] = "application/vnd.api+json"; ContentType["FormData"] = "multipart/form-data"; ContentType["UrlEncoded"] = "application/x-www-form-urlencoded"; ContentType["Text"] = "text/plain"; })(ContentType || (ContentType = {})); export class HttpClient { constructor(_a = {}) { var { securityWorker, secure, format } = _a, axiosConfig = __rest(_a, ["securityWorker", "secure", "format"]); this.securityData = null; this.setSecurityData = (data) => { this.securityData = data; }; this.request = (_a) => __awaiter(this, void 0, void 0, function* () { var { secure, path, type, query, format, body } = _a, params = __rest(_a, ["secure", "path", "type", "query", "format", "body"]); const secureParams = ((typeof secure === "boolean" ? secure : this.secure) && this.securityWorker && (yield this.securityWorker(this.securityData))) || {}; const requestParams = this.mergeRequestParams(params, secureParams); const responseFormat = format || this.format || undefined; if (type === ContentType.FormData && body && body !== null && typeof body === "object") { body = this.createFormData(body); } if (type === ContentType.Text && body && body !== null && typeof body !== "string") { body = JSON.stringify(body); } return this.instance.request(Object.assign(Object.assign({}, requestParams), { headers: Object.assign(Object.assign({}, (requestParams.headers || {})), (type ? { "Content-Type": type } : {})), params: query, responseType: responseFormat, data: body, url: path })); }); this.instance = axios.create(Object.assign(Object.assign({}, axiosConfig), { baseURL: axiosConfig.baseURL || "" })); this.secure = secure; this.format = format; this.securityWorker = securityWorker; } mergeRequestParams(params1, params2) { const method = params1.method || (params2 && params2.method); return Object.assign(Object.assign(Object.assign(Object.assign({}, this.instance.defaults), params1), (params2 || {})), { headers: Object.assign(Object.assign(Object.assign({}, ((method && this.instance.defaults.headers[method.toLowerCase()]) || {})), (params1.headers || {})), ((params2 && params2.headers) || {})) }); } stringifyFormItem(formItem) { if (typeof formItem === "object" && formItem !== null) { return JSON.stringify(formItem); } else { return `${formItem}`; } } createFormData(input) { if (input instanceof FormData) { return input; } return Object.keys(input || {}).reduce((formData, key) => { const property = input[key]; const propertyContent = property instanceof Array ? property : [property]; for (const formItem of propertyContent) { const isFileType = formItem instanceof Blob || formItem instanceof File; formData.append(key, isFileType ? formItem : this.stringifyFormItem(formItem)); } return formData; }, new FormData()); } } /** * @title The Big POS API * @version v2.27.3 * @termsOfService https://www.thebigpos.com/terms-of-use/ * @contact Mortgage Automation Technologies <support@thebigpos.com> (https://www.thebigpos.com/terms-of-use/) */ export class Api extends HttpClient { constructor() { super(...arguments); /** * No description * * @tags Saml * @name PostRoot * @request POST:/ * @secure * @response `200` `void` Success */ this.postRoot = (params = {}) => this.request(Object.assign({ path: `/`, method: "POST", secure: true }, params)); /** * No description * * @tags TheBigPOS * @name GetRoot * @request GET:/ * @secure * @response `200` `string` Success */ this.getRoot = (params = {}) => this.request(Object.assign({ path: `/`, method: "GET", secure: true }, params)); this.api = { /** * No description * * @tags Account * @name GetMyAccount * @summary Get * @request GET:/api/account * @secure * @response `200` `Account` Success * @response `404` `ProblemDetails` Not Found */ getMyAccount: (params = {}) => this.request(Object.assign({ path: `/api/account`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Account * @name ReplaceMyAccount * @summary Replace * @request PUT:/api/account * @secure * @response `200` `Account` Success * @response `404` `ProblemDetails` Not Found * @response `422` `ProblemDetails` Client Error */ replaceMyAccount: (data, params = {}) => this.request(Object.assign({ path: `/api/account`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Account * @name GetSiteConfigurationByAccount * @summary Get Site Configuration * @request GET:/api/account/site-configurations * @secure * @response `200` `SiteConfiguration` Success */ getSiteConfigurationByAccount: (params = {}) => this.request(Object.assign({ path: `/api/account/site-configurations`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Account * @name UpdateSiteConfigurationForAccount * @summary Update Site Configuration * @request PUT:/api/account/site-configurations * @secure * @response `200` `SiteConfiguration` Success * @response `422` `UnprocessableEntity` Client Error */ updateSiteConfigurationForAccount: (data, params = {}) => this.request(Object.assign({ path: `/api/account/site-configurations`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Accounts * @name GetAccounts * @summary Get All * @request GET:/api/accounts * @secure * @response `200` `(Account)[]` Success */ getAccounts: (params = {}) => this.request(Object.assign({ path: `/api/accounts`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Accounts * @name CreateAccount * @summary Create * @request POST:/api/accounts * @secure * @response `201` `Account` Created * @response `422` `ProblemDetails` Client Error */ createAccount: (data, params = {}) => this.request(Object.assign({ path: `/api/accounts`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Accounts * @name GetAccount * @summary Get by ID * @request GET:/api/accounts/{id} * @secure * @response `201` `Account` Created * @response `422` `ProblemDetails` Client Error */ getAccount: (id, params = {}) => this.request(Object.assign({ path: `/api/accounts/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Accounts * @name DeleteAccount * @summary Delete * @request DELETE:/api/accounts/{id} * @secure * @response `204` `Account` No Content * @response `404` `ProblemDetails` Not Found * @response `422` `ProblemDetails` Client Error */ deleteAccount: (id, query, params = {}) => this.request(Object.assign({ path: `/api/accounts/${id}`, method: "DELETE", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags Accounts * @name UpdateLoansByAccount * @summary Update Loans * @request PUT:/api/accounts/{id}/loan * @secure * @response `200` `void` Success * @response `404` `ProblemDetails` Not Found * @response `422` `UnprocessableEntity` Client Error */ updateLoansByAccount: (id, data, params = {}) => this.request(Object.assign({ path: `/api/accounts/${id}/loan`, method: "PUT", body: data, secure: true, type: ContentType.Json }, params)), /** * No description * * @tags Accounts * @name GetLoansByAccount * @summary Get Loans * @request GET:/api/accounts/{id}/loan * @secure * @response `200` `(Loan)[]` Success * @response `404` `ProblemDetails` Not Found */ getLoansByAccount: (id, params = {}) => this.request(Object.assign({ path: `/api/accounts/${id}/loan`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Authentication * @name GetTokenFromRefreshToken * @summary Generate Token From Refresh Token * @request POST:/api/refresh-token * @secure * @response `200` `Token` Success * @response `422` `UnprocessableEntity` Client Error */ getTokenFromRefreshToken: (data, params = {}) => this.request(Object.assign({ path: `/api/refresh-token`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Authentication * @name GetToken * @summary Get Token * @request POST:/api/token * @secure * @response `200` `Token` Success * @response `422` `UnprocessableEntity` Client Error */ getToken: (data, params = {}) => this.request(Object.assign({ path: `/api/token`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Authentication * @name GetTokenFromChallengeCode * @summary Get Token From Challenge Code * @request POST:/api/token/code * @secure * @response `200` `Token` Success * @response `422` `UnprocessableEntity` Client Error */ getTokenFromChallengeCode: (data, params = {}) => this.request(Object.assign({ path: `/api/token/code`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Authentication * @name GetSystemToken * @summary Get System Token * @request POST:/api/oauth2/token * @secure * @response `200` `Token` Success * @response `422` `UnprocessableEntity` Client Error */ getSystemToken: (data, params = {}) => this.request(Object.assign({ path: `/api/oauth2/token`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Authentication * @name GetSsoToken * @summary Get SSO Guid Token * @request POST:/api/token/sso * @secure * @response `200` `SSOToken` Success * @response `422` `UnprocessableEntity` Client Error */ getSsoToken: (data, params = {}) => this.request(Object.assign({ path: `/api/token/sso`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Authentication * @name LogOut * @summary Sign out (clear auth cookies) * @request POST:/api/logout * @secure * @response `204` `void` No Content * @response `422` `UnprocessableEntity` Client Error */ logOut: (params = {}) => this.request(Object.assign({ path: `/api/logout`, method: "POST", secure: true }, params)), /** * No description * * @tags Branches * @name GetBranches * @summary Get All * @request GET:/api/branches * @secure * @response `200` `GetBranchPaginated` Success */ getBranches: (query, params = {}) => this.request(Object.assign({ path: `/api/branches`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags Branches * @name CreateBranch * @summary Create * @request POST:/api/branches * @secure * @response `200` `GetBranch` Success * @response `422` `UnprocessableEntity` Client Error */ createBranch: (data, params = {}) => this.request(Object.assign({ path: `/api/branches`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Branches * @name SearchBranches * @summary Search * @request POST:/api/branches/search * @secure * @response `200` `GetBranchPaginated` Success */ searchBranches: (data, query, params = {}) => this.request(Object.assign({ path: `/api/branches/search`, method: "POST", query: query, body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Branches * @name GetBranch * @summary Get by ID * @request GET:/api/branches/{branchId} * @secure * @response `200` `GetBranch` Success */ getBranch: (branchId, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Branches * @name ReplaceBranch * @summary Replace * @request PUT:/api/branches/{branchId} * @secure * @response `200` `GetBranch` Success * @response `422` `UnprocessableEntity` Client Error */ replaceBranch: (branchId, data, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Branches * @name DeleteBranch * @summary Delete * @request DELETE:/api/branches/{branchId} * @secure * @response `204` `void` No Content */ deleteBranch: (branchId, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags Branches * @name RestoreBranch * @summary Restore * @request POST:/api/branches/{branchId}/restore * @secure * @response `204` `void` No Content * @response `400` `ProblemDetails` Bad Request */ restoreBranch: (branchId, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}/restore`, method: "POST", secure: true }, params)), /** * No description * * @tags Branches * @name CreateBranchSiteConfiguration * @summary Create Branch Site Configuration * @request POST:/api/branches/{branchId}/site-configurations * @secure * @response `200` `SiteConfiguration` Success * @response `422` `UnprocessableEntity` Client Error */ createBranchSiteConfiguration: (branchId, data, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}/site-configurations`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Branches * @name GetBranchSiteConfiguration * @summary Get Branch Site Configuration * @request GET:/api/branches/{branchId}/site-configurations/{siteConfigurationId} * @secure * @response `200` `SiteConfigurationWithInherited` Success */ getBranchSiteConfiguration: (branchId, siteConfigurationId, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}/site-configurations/${siteConfigurationId}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Branches * @name ReplaceBranchSiteConfiguration * @summary Replace Branch Site Configuration * @request PUT:/api/branches/{branchId}/site-configurations/{siteConfigurationId} * @secure * @response `200` `SiteConfiguration` Success * @response `422` `UnprocessableEntity` Client Error */ replaceBranchSiteConfiguration: (branchId, siteConfigurationId, data, query, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}/site-configurations/${siteConfigurationId}`, method: "PUT", query: query, body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Branches * @name GetLoanOfficersByBranch * @summary Get Branch Loan Officers * @request GET:/api/branches/{branchId}/loan-officers * @secure * @response `200` `LoanOfficerPublic` Success */ getLoanOfficersByBranch: (branchId, params = {}) => this.request(Object.assign({ path: `/api/branches/${branchId}/loan-officers`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags BusinessRules * @name GetBusinessRules * @summary Get All * @request GET:/api/business-rules * @secure * @response `200` `(BusinessRule)[]` Success */ getBusinessRules: (query, params = {}) => this.request(Object.assign({ path: `/api/business-rules`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags BusinessRules * @name CreateBusinessRule * @summary Create * @request POST:/api/business-rules * @secure * @response `200` `BusinessRule` Success * @response `422` `UnprocessableEntity` Client Error */ createBusinessRule: (data, params = {}) => this.request(Object.assign({ path: `/api/business-rules`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags BusinessRules * @name GetBusinessRule * @summary Get by ID * @request GET:/api/business-rules/{id} * @secure * @response `200` `BusinessRule` Success */ getBusinessRule: (id, params = {}) => this.request(Object.assign({ path: `/api/business-rules/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags BusinessRules * @name ReplaceBusinessRule * @summary Replace * @request PUT:/api/business-rules/{id} * @secure * @response `200` `BusinessRule` Success * @response `422` `UnprocessableEntity` Client Error */ replaceBusinessRule: (id, data, params = {}) => this.request(Object.assign({ path: `/api/business-rules/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags BusinessRules * @name DeleteBusinessRule * @summary Delete * @request DELETE:/api/business-rules/{id} * @secure * @response `204` `void` No Content */ deleteBusinessRule: (id, params = {}) => this.request(Object.assign({ path: `/api/business-rules/${id}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags BusinessRules * @name RestoreBusinessRule * @summary Restore * @request POST:/api/business-rules/{id}/restore * @secure * @response `200` `BusinessRule` Success */ restoreBusinessRule: (id, params = {}) => this.request(Object.assign({ path: `/api/business-rules/${id}/restore`, method: "POST", secure: true, format: "json" }, params)), /** * No description * * @tags Corporates * @name GetCorporates * @summary Get All * @request GET:/api/corporates * @secure * @response `200` `CorporatePaginated` Success */ getCorporates: (query, params = {}) => this.request(Object.assign({ path: `/api/corporates`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags Corporates * @name CreateCorporate * @summary Create * @request POST:/api/corporates * @secure * @response `200` `Corporate` Success * @response `422` `UnprocessableEntity` Client Error */ createCorporate: (data, params = {}) => this.request(Object.assign({ path: `/api/corporates`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Corporates * @name SearchCorporate * @summary Search * @request POST:/api/corporates/search * @secure * @response `200` `CorporatePaginated` Success */ searchCorporate: (data, query, params = {}) => this.request(Object.assign({ path: `/api/corporates/search`, method: "POST", query: query, body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Corporates * @name GetCorporate * @summary Get by ID * @request GET:/api/corporates/{id} * @secure * @response `200` `Corporate` Success */ getCorporate: (id, params = {}) => this.request(Object.assign({ path: `/api/corporates/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Corporates * @name ReplaceCorporate * @summary Replace * @request PUT:/api/corporates/{id} * @secure * @response `200` `Corporate` Success * @response `422` `UnprocessableEntity` Client Error */ replaceCorporate: (id, data, params = {}) => this.request(Object.assign({ path: `/api/corporates/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Corporates * @name DeleteCorporate * @summary Delete * @request DELETE:/api/corporates/{id} * @secure * @response `204` `void` No Content */ deleteCorporate: (id, params = {}) => this.request(Object.assign({ path: `/api/corporates/${id}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags Corporates * @name RestoreCorporate * @summary Restore * @request POST:/api/corporates/{id}/restore * @secure * @response `204` `void` No Content */ restoreCorporate: (id, params = {}) => this.request(Object.assign({ path: `/api/corporates/${id}/restore`, method: "POST", secure: true }, params)), /** * No description * * @tags Corporates * @name CreateCorporateSiteConfiguration * @summary Create Site Configuration * @request POST:/api/corporates/{corporateId}/site-configurations * @secure * @response `200` `SiteConfiguration` Success * @response `422` `UnprocessableEntity` Client Error */ createCorporateSiteConfiguration: (corporateId, data, params = {}) => this.request(Object.assign({ path: `/api/corporates/${corporateId}/site-configurations`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Corporates * @name GetCorporateSiteConfiguration * @summary Get Site Configuration * @request GET:/api/corporates/{corporateId}/site-configurations/{siteConfigurationId} * @secure * @response `200` `SiteConfigurationWithInherited` Success */ getCorporateSiteConfiguration: (corporateId, siteConfigurationId, params = {}) => this.request(Object.assign({ path: `/api/corporates/${corporateId}/site-configurations/${siteConfigurationId}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Corporates * @name ReplaceCorporateSiteConfiguration * @summary Replace Site Configuration * @request PUT:/api/corporates/{corporateId}/site-configurations/{siteConfigurationId} * @secure * @response `200` `SiteConfiguration` Success * @response `422` `UnprocessableEntity` Client Error */ replaceCorporateSiteConfiguration: (corporateId, siteConfigurationId, data, query, params = {}) => this.request(Object.assign({ path: `/api/corporates/${corporateId}/site-configurations/${siteConfigurationId}`, method: "PUT", query: query, body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Corporates * @name GetBranchesByCorporate * @summary Get Branches * @request GET:/api/corporates/{id}/branches * @secure * @response `200` `(BranchReduced)[]` Success */ getBranchesByCorporate: (id, params = {}) => this.request(Object.assign({ path: `/api/corporates/${id}/branches`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Corporates * @name GetLoanOfficersByCorporate * @summary Get Loan Officers * @request GET:/api/corporates/{id}/loan-officers * @secure * @response `200` `LoanOfficerPublic` Success */ getLoanOfficersByCorporate: (id, params = {}) => this.request(Object.assign({ path: `/api/corporates/${id}/loan-officers`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Devices * @name GetDevices * @summary Get All * @request GET:/api/devices * @secure * @response `200` `DevicePaginated` Success */ getDevices: (query, params = {}) => this.request(Object.assign({ path: `/api/devices`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags Devices * @name GetDevice * @summary Get by ID * @request GET:/api/devices/{id} * @secure * @response `200` `Device` Success */ getDevice: (id, params = {}) => this.request(Object.assign({ path: `/api/devices/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Devices * @name UpdateDevice * @summary Update * @request PUT:/api/devices/{id} * @secure * @response `200` `Device` Success */ updateDevice: (id, data, params = {}) => this.request(Object.assign({ path: `/api/devices/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Devices * @name GetDeviceBySerialNumber * @summary Get by Serial Number * @request GET:/api/devices/{sn}/profile * @secure * @response `200` `DeviceMDM` Success */ getDeviceBySerialNumber: (sn, params = {}) => this.request(Object.assign({ path: `/api/devices/${sn}/profile`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Devices * @name CreateDeviceActionBySerialNumber * @summary Create Action by Serial Number * @request POST:/api/devices/{sn}/actions/{actionName} * @secure * @response `200` `Action` Success */ createDeviceActionBySerialNumber: (sn, actionName, params = {}) => this.request(Object.assign({ path: `/api/devices/${sn}/actions/${actionName}`, method: "POST", secure: true, format: "json" }, params)), /** * No description * * @tags DocumentBuckets * @name GetDocumentBuckets * @summary Get All * @request GET:/api/document-buckets * @secure * @response `200` `(string)[]` Success */ getDocumentBuckets: (query, params = {}) => this.request(Object.assign({ path: `/api/document-buckets`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags DocumentTemplates * @name GetDocumentTemplates * @summary Get All * @request GET:/api/document-templates * @secure * @response `200` `(DocumentTemplateBase)[]` Success */ getDocumentTemplates: (query, params = {}) => this.request(Object.assign({ path: `/api/document-templates`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags DocumentTemplates * @name CreateDocumentTemplate * @summary Create * @request POST:/api/document-templates * @secure * @response `201` `DocumentTemplateBase` Created * @response `404` `ProblemDetails` Not Found * @response `422` `UnprocessableEntity` Client Error */ createDocumentTemplate: (data, params = {}) => this.request(Object.assign({ path: `/api/document-templates`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags DocumentTemplates * @name GetCustomDocumentTemplates * @summary Get Custom * @request GET:/api/document-templates/{type} * @secure * @response `200` `(DocumentTemplateBase)[]` Success */ getCustomDocumentTemplates: (type, query, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${type}`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags DocumentTemplates * @name GetDocumentTemplate * @summary Get By ID * @request GET:/api/document-templates/{id} * @secure * @response `200` `DocumentTemplate` Success * @response `404` `ProblemDetails` Not Found */ getDocumentTemplate: (id, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags DocumentTemplates * @name ReplaceDocumentTemplate * @summary Replace * @request PUT:/api/document-templates/{id} * @secure * @response `200` `DocumentTemplateBase` Success * @response `401` `ProblemDetails` Unauthorized * @response `404` `ProblemDetails` Not Found * @response `422` `UnprocessableEntity` Client Error */ replaceDocumentTemplate: (id, data, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags DocumentTemplates * @name DeleteDocumentTemplate * @summary Delete * @request DELETE:/api/document-templates/{id} * @secure * @response `204` `void` No Content * @response `401` `ProblemDetails` Unauthorized * @response `404` `ProblemDetails` Not Found */ deleteDocumentTemplate: (id, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${id}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags DocumentTemplates * @name RestoreDocumentTemplate * @summary Restore * @request POST:/api/document-templates/{id}/restore * @secure * @response `204` `void` No Content * @response `401` `ProblemDetails` Unauthorized * @response `404` `ProblemDetails` Not Found */ restoreDocumentTemplate: (id, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${id}/restore`, method: "POST", secure: true }, params)), /** * No description * * @tags DocumentTemplateVersions * @name GetDocumentTemplateVersions * @summary Get All * @request GET:/api/document-templates/{documentId}/versions * @secure * @response `200` `(DocumentTemplateVersion)[]` Success */ getDocumentTemplateVersions: (documentId, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${documentId}/versions`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags DocumentTemplateVersions * @name CreateDocumentTemplateVersion * @summary Create * @request POST:/api/document-templates/{documentId}/versions * @secure * @response `200` `DocumentTemplateVersion` Success */ createDocumentTemplateVersion: (documentId, data, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${documentId}/versions`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags DocumentTemplateVersions * @name GetDocumentTemplateVersion * @summary Get by ID * @request GET:/api/document-templates/{documentId}/versions/{id} * @secure * @response `200` `DocumentTemplateVersion` Success */ getDocumentTemplateVersion: (documentId, id, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${documentId}/versions/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags DocumentTemplateVersions * @name ReplaceDocumentTemplateVersion * @summary Replace * @request PUT:/api/document-templates/{documentId}/versions/{id} * @secure * @response `200` `DocumentTemplateVersion` Success */ replaceDocumentTemplateVersion: (documentId, id, data, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${documentId}/versions/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags DocumentTemplateVersions * @name DeleteDocumentTemplateVersion * @summary Delete * @request DELETE:/api/document-templates/{documentId}/versions/{id} * @secure * @response `200` `DocumentTemplateVersion` Success */ deleteDocumentTemplateVersion: (documentId, id, params = {}) => this.request(Object.assign({ path: `/api/document-templates/${documentId}/versions/${id}`, method: "DELETE", secure: true, format: "json" }, params)), /** * No description * * @tags Files * @name GetAllFiles * @summary Get All * @request GET:/api/files * @secure * @response `200` `FilePaginated` Success */ getAllFiles: (query, params = {}) => this.request(Object.assign({ path: `/api/files`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags Files * @name UploadFile * @summary Upload * @request POST:/api/files * @secure * @response `201` `File` Created * @response `422` `UnprocessableEntity` Client Error */ uploadFile: (data, params = {}) => this.request(Object.assign({ path: `/api/files`, method: "POST", body: data, secure: true, type: ContentType.FormData, format: "json" }, params)), /** * No description * * @tags Files * @name GetFileById * @summary Get By ID * @request GET:/api/files/{id} * @secure * @response `201` `File` Created */ getFileById: (id, params = {}) => this.request(Object.assign({ path: `/api/files/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Files * @name ReplaceFile * @summary Replace * @request PUT:/api/files/{id} * @secure * @response `200` `string` Success * @response `422` `UnprocessableEntity` Client Error */ replaceFile: (id, data, params = {}) => this.request(Object.assign({ path: `/api/files/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Files * @name DeleteFile * @summary Delete * @request DELETE:/api/files/{id} * @secure * @response `204` `void` No Content */ deleteFile: (id, params = {}) => this.request(Object.assign({ path: `/api/files/${id}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags Files * @name SearchFiles * @summary Search * @request POST:/api/files/search * @secure * @response `200` `FilePaginated` Success */ searchFiles: (data, query, params = {}) => this.request(Object.assign({ path: `/api/files/search`, method: "POST", query: query, body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Forms * @name GetForms * @summary Get All * @request GET:/api/forms * @secure * @response `200` `(AdminAccessGetForms)[]` Success */ getForms: (query, params = {}) => this.request(Object.assign({ path: `/api/forms`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags Forms * @name CreateForm * @summary Create * @request POST:/api/forms * @secure * @response `201` `Form` Created * @response `422` `UnprocessableEntity` Client Error */ createForm: (data, params = {}) => this.request(Object.assign({ path: `/api/forms`, method: "POST", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Forms * @name GetForm * @summary Get By ID * @request GET:/api/forms/{id} * @secure * @response `200` `Form` Success */ getForm: (id, params = {}) => this.request(Object.assign({ path: `/api/forms/${id}`, method: "GET", secure: true, format: "json" }, params)), /** * No description * * @tags Forms * @name ReplaceForm * @summary Replace * @request PUT:/api/forms/{id} * @secure * @response `200` `Form` Success * @response `422` `UnprocessableEntity` Client Error */ replaceForm: (id, data, params = {}) => this.request(Object.assign({ path: `/api/forms/${id}`, method: "PUT", body: data, secure: true, type: ContentType.Json, format: "json" }, params)), /** * No description * * @tags Forms * @name DeleteForm * @summary Delete * @request DELETE:/api/forms/{id} * @secure * @response `204` `void` No Content */ deleteForm: (id, params = {}) => this.request(Object.assign({ path: `/api/forms/${id}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags Forms * @name RestoreForm * @summary Restore * @request POST:/api/forms/{id}/restore * @secure * @response `200` `Form` Success */ restoreForm: (id, params = {}) => this.request(Object.assign({ path: `/api/forms/${id}/restore`, method: "POST", secure: true, format: "json" }, params)), /** * No description * * @tags FormSubmissionFiles * @name AddFormSubmissionFile * @summary Add * @request POST:/api/form-submissions/{formSubmissionId}/files * @secure * @response `200` `FormSubmissionFile` Success */ addFormSubmissionFile: (formSubmissionId, data, params = {}) => this.request(Object.assign({ path: `/api/form-submissions/${formSubmissionId}/files`, method: "POST", body: data, secure: true, type: ContentType.FormData, format: "json" }, params)), /** * No description * * @tags FormSubmissionFiles * @name DeleteFormSubmissionFile * @summary Delete * @request DELETE:/api/form-submissions/{formSubmissionId}/files/{formSubmissionFileId} * @secure * @response `204` `void` No Content */ deleteFormSubmissionFile: (formSubmissionFileId, formSubmissionId, params = {}) => this.request(Object.assign({ path: `/api/form-submissions/${formSubmissionId}/files/${formSubmissionFileId}`, method: "DELETE", secure: true }, params)), /** * No description * * @tags FormSubmissionFiles * @name DownloadFormSubmissionFile * @summary Download by Id * @request GET:/api/form-submissions/{formSubmissionId}/files/{formSubmissionFileId}/download * @secure * @response `200` `FileWithBytes` Success */ downloadFormSubmissionFile: (formSubmissionFileId, formSubmissionId, query, params = {}) => this.request(Object.assign({ path: `/api/form-submissions/${formSubmissionId}/files/${formSubmissionFileId}/download`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags FormSubmissions * @name GetFormSubmissions * @summary Get All * @request GET:/api/form-submissions * @secure * @response `200` `FormSubmissionPaginated` Success */ getFormSubmissions: (query, params = {}) => this.request(Object.assign({ path: `/api/form-submissions`, method: "GET", query: query, secure: true, format: "json" }, params)), /** * No description * * @tags FormSubmissions * @name CreateFormSubmission * @summary Create * @request POST:/api/form-submis