"use strict";
export class JsonDto {
constructor(init) { Object.assign(this, init) }
}
export class JsonRequestDto extends JsonDto {
/** @param {{ClientCode?:string,ClientRegistrationCode?:string,Token?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {string} */
ClientCode;
/** @type {string} */
ClientRegistrationCode;
/** @type {string} */
Token;
}
export class JsonMetadataUploadRequest extends JsonRequestDto {
/** @param {{UploadFileName?:string,OriginalFileName?:string,TemplateGuid?:string,ClientIpAddress?:string,ClientGuid?:string,ClientName?:string,ClientId?:string,ClientSerialNumber?:string,UserName?:string,UserEmail?:string,UserHomeFolder?:string,TemplateQuestions?:{ [index: string]: string; },GlobalQuestions?:{ [index: string]: string; },ClientCode?:string,ClientRegistrationCode?:string,Token?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {string} */
UploadFileName;
/** @type {string} */
OriginalFileName;
/** @type {string} */
TemplateGuid;
/** @type {string} */
ClientIpAddress;
/** @type {string} */
ClientGuid;
/** @type {string} */
ClientName;
/** @type {string} */
ClientId;
/** @type {string} */
ClientSerialNumber;
/** @type {string} */
UserName;
/** @type {string} */
UserEmail;
/** @type {string} */
UserHomeFolder;
/** @type {{ [index: string]: string; }} */
TemplateQuestions;
/** @type {{ [index: string]: string; }} */
GlobalQuestions;
}
export class JsonMetadataUploadResponse extends JsonDto {
/** @param {{TemplateGuid?:string,InError?:boolean,ErrorMessage?:string}} [init] */
constructor(init) { super(init); Object.assign(this, init) }
/** @type {string} */
TemplateGuid;
/** @type {boolean} */
InError;
/** @type {string} */
ErrorMessage;
}
JavaScript JsonMetadataUploadRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /jsv/reply/JsonMetadataUploadRequest HTTP/1.1
Host: buildmax.org
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
UploadFileName: String,
OriginalFileName: String,
TemplateGuid: String,
ClientIpAddress: String,
ClientGuid: String,
ClientName: String,
ClientId: String,
ClientSerialNumber: String,
UserName: String,
UserEmail: String,
UserHomeFolder: String,
ClientCode: String,
ClientRegistrationCode: String,
Token: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
TemplateGuid: String,
InError: False,
ErrorMessage: String
}