DigiOffice Gateway Web Services

<back to all web services

UploadFile

Requires Authentication
The following routes are available for this service:
POST/api/DMS/UploadFile

// @DataContract
export class MetaDataField
{
    // @DataMember
    public ID?: string;

    // @DataMember
    public DocumentVeldID?: string;

    // @DataMember
    public Name: string;

    // @DataMember
    public Label: string;

    // @DataMember
    public Datatype: string;

    // @DataMember
    public PrintLabel: string;

    // @DataMember
    public Entity: string;

    // @DataMember
    public PrintValue: string;

    // @DataMember
    public RegistrationValue: string;

    // @DataMember
    public SPSiteColumnName: string;

    // @DataMember
    public ShadowName: string;

    // @DataMember
    public ShadowDatatype: string;

    // @DataMember
    public ShadowSPSiteColumnName: string;

    // @DataMember
    public ShadowSPSiteColumnRegistrationValue: string;

    // @DataMember
    public ShadowRegistrationValue: string;

    // @DataMember
    public IsKeyField: boolean;

    // @DataMember
    public KopierenBijNieuweVersie: boolean;

    public constructor(init?: Partial<MetaDataField>) { (Object as any).assign(this, init); }
}

export class UploadFile
{
    public RegistrationProfileID: string;
    public NavigationPath: string;
    public FileName: string;
    public FileDate?: string;
    public Description: string;
    public DocumentUpload: boolean;
    public Source: string;
    public MetaData: MetaDataField[];
    public DocumentID?: string;
    public HoofdDocumentID?: string;
    public SubDocumentIDs: string[];

    public constructor(init?: Partial<UploadFile>) { (Object as any).assign(this, init); }
}

export enum MessageType
{
    Information = 1,
    Warning = 2,
    Error = 3,
    Success = 4,
}

export class InformationMessageBase implements IInformationMessage
{
    public Type: MessageType;
    public Summary: string;
    public FullMessage: string;
    public FieldName: string;
    public KeepOpen: boolean;

    public constructor(init?: Partial<InformationMessageBase>) { (Object as any).assign(this, init); }
}

export class InformationMessages extends Array<InformationMessageBase> implements IInformationMessages
{

    public constructor(init?: Partial<InformationMessages>) { super(); (Object as any).assign(this, init); }
}

// @DataContract
export class UploadFileResponse
{
    // @DataMember
    public DocumentId?: string;

    // @DataMember
    public DocumentUploadId?: number;

    // @DataMember
    public DocumentNr: string;

    // @DataMember
    public Messages: InformationMessages;

    public constructor(init?: Partial<UploadFileResponse>) { (Object as any).assign(this, init); }
}

TypeScript UploadFile 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/DMS/UploadFile HTTP/1.1 
Host: doapigw.baasbv.nl 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	NavigationPath: String,
	FileName: String,
	FileDate: 0001-01-01,
	Description: String,
	DocumentUpload: False,
	Source: String,
	MetaData: 
	[
		{
			ID: 00000000-0000-0000-0000-000000000000,
			DocumentVeldID: 00000000-0000-0000-0000-000000000000,
			Name: String,
			Label: String,
			Datatype: String,
			PrintLabel: String,
			Entity: String,
			PrintValue: String,
			RegistrationValue: String,
			SPSiteColumnName: String,
			ShadowName: String,
			ShadowDatatype: String,
			ShadowSPSiteColumnName: String,
			ShadowSPSiteColumnRegistrationValue: String,
			ShadowRegistrationValue: String,
			IsKeyField: False,
			KopierenBijNieuweVersie: False
		}
	],
	DocumentID: 00000000-0000-0000-0000-000000000000,
	HoofdDocumentID: 00000000-0000-0000-0000-000000000000,
	SubDocumentIDs: 
	[
		00000000-0000-0000-0000-000000000000
	]
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	DocumentId: 00000000-0000-0000-0000-000000000000,
	DocumentUploadId: 0,
	DocumentNr: String,
	Messages: 
	[
		{
			
		}
	]
}