DigiOffice Gateway Web Services

<back to all web services

GenerateDraftWordDocument

Generate a new or update a (corporate identity) MS Word document without registration.

Requires Authentication
The following routes are available for this service:
POST/api/documentgenerator/word/generatedraftdocument
"use strict";
export class DocumentBase64File {
    /** @param {{ContentType?:string,Content?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {string} */
    ContentType;
    /** @type {string} */
    Content;
}
export class GenerateDraftWordDocumentResponse {
    /** @param {{File?:DocumentBase64File}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {DocumentBase64File}
     * @description Contains the file */
    File;
}
export class GenerateDraftWordDocument {
    /** @param {{DocumentInfo?:string,CustomData?:string,File?:DocumentBase64File}} [init] */
    constructor(init) { Object.assign(this, init) }
    /**
     * @type {string}
     * @description The DocumentInfo result of the registration wizard. */
    DocumentInfo;
    /**
     * @type {string}
     * @description Hier kan de (dynamische) data voor het document geplaatst worden, de data kan middels tekstblokken en placeholders worden geplaatst.Het formaat binnen CustomData staat vrij maar vereist een 'root' element. */
    CustomData;
    /**
     * @type {DocumentBase64File}
     * @description The document to update. */
    File;
}

JavaScript GenerateDraftWordDocument DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /api/documentgenerator/word/generatedraftdocument HTTP/1.1 
Host: dogw.klokgroep.nl 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	DocumentInfo: String,
	CustomData: String,
	File: 
	{
		ContentType: String,
		Content: String
	}
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	File: 
	{
		ContentType: String,
		Content: String
	}
}