# Send Document v3.1

This API is used to send a document to an enabled company, user or group. The sent document will be visible in the sender’s outbox and the receiver’s inbox when the API execution is complete. If the receiver is outside the platform alternative delivery channels will be used. The request and response format for the “SendDocument” API are given below:

The type of the document is specified by the TemplateId. The sender is indicated with Via.

# Header fields

Fieldname Description
SOAPAction Mandatory http://api.everbinding.nl/v3_1/SendDocument

# Request fields

Fieldname Description
Via Mandatory ReferenceId of the sender of the document. This must be a verified id. Preferred id is the EConnectPartyId.
To Mandatory ReferenceId of the receiver of the document.
ReferenceId Mandatory One of the Ids available for identifying a party. This can be an EConnectPartyId or a ID that is registered in external registries like NL:KVK:nnnnnnnn or NL:VAT:NLnnnnnnnBnn etc.
EmailAddress Optional Address to be used as fallback when the recipient is not found in the network. If no e-mail address is provided and the receiver is not reachable in the network then this function will respond with error ERRSND4000001.
Subject* Mandatory Name used for the document within eConnect.
Payload Mandatory XML document without the XML prolog.
TemplateId Mandatory TemplateId is the id that indicates the type of document.

*Subject will be overwritten by our platform to {template} {invoiceid}.

# Example request

<?xml version="1.0" ?>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
    <S:Header>
        <h:Authentication xmlns="http://api.everbinding.nl/v3_1/" xmlns:h="http://api.everbinding.nl/v3_1/">
            <SecurityToken>o2S1qTusL29hp3IgMKWsn2I5CFV2LmZ2ZmR2AQp4AGN0BQZmATH3ZwHkAQH1LGL2AGx0VvkiLKI0nS9ho25wMG0vZGZjZwRkZGx2AvVfo2S1qTusqTygMKA0LJ1jCFVkAGN1ZGV1ZGVlVvkiLKI0nS9mnJqhLKE1pzIsoJI0nT9xCFWVGHSQYIAVDGRvYT9uqKEbK3MypaAco249VwRhZPVfo2S1qTusqT9eMJ49Vx9zAQqFESD3FRVlpaERnQAYI2SLnaAbA2uLIyEOIz55VvkiLKI0nS9mnJqhLKE1pzH9Vzy5L1p2oT91MvHlEzcnDaIxH3V5qxA4nx9VoHESWGARVt==</SecurityToken>
        </h:Authentication>
    </S:Header>
    <S:Body xmlns="http://api.everbinding.nl/v3_1/">
        <SendDocument xmlns="http://api.everbinding.nl/v3_1/">
            <Via>
                <ReferenceId>XCNL10019</ReferenceId>
            </Via>
            <To>
                <ReferenceId>XCNL10018</ReferenceId>
                <EmailAddress>techsupport@econnect.eu</EmailAddress>
            </To>
            <Subject>Unit test SendDoc 1505125121773</Subject>
        <Payload>
            .
            .
            .
        </Payload>
            <TemplateId>GLDT9223370666504283001RA000000006DTP2000001</TemplateId>
        </SendDocument>
    </S:Body>
</S:Envelope>

# Response fields

Fieldname Description
ExternalId ExternalId identifies the document has been send. The ExternalId can be used as prove that the document is send. Without a ExternalId a document can be considered as not send.

# Response 200

<?xml version="1.0" encoding="utf-8"?>
<SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
    <SOAP:Body>
        <SendDocumentResponse xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://api.everbinding.nl/v3_1/">
            <ExternalId>XCNIN97713</ExternalId>
        </SendDocumentResponse>
    </SOAP:Body>
</SOAP:Envelope>

# Example errors

Error code Error text
ERRGRP3000006 You do not have permission to send document via the specified group. The specified group is the company-ID used with Via
ERRXSL4000001 There was an error in validating the payload with XSL. The errors coming from the XSLT are returned via faultstring Example: [BII2-T10-R003]-An invoice MUST have an invoice identifier
ERRSND8000002 Document verzenden mislukt
ERRSND8000001 Processing of send document from collabrr to oxalis failed
ERRSND2000001 Invoices may not be able to send, without a business context(sendvia)
ERRSND4000001 Recipient EmailId should not be empty while staging the document
ERRSND4000002 The email address specified is invalid.
ERRGRP4000001 The specified group does not exist.
ERRCON5000018 Formaat van Recipient waarde is niet juist of wordt niet herkend. Document niet verstuurd.
© 2024 eConnect International B.V.