Attachments

As a default, KSeF does not accept any attachments. It is not possible to forward anything except Faktura FA(3) Object.

However, A-Cube platform supports additional information about attachments in sended payload. To do this, Attachments and Faktura Object must be wrapped by Invoice object.

Copy
Copied
<?xml version="1.0" encoding="utf-8"?>
<invoice>
  <?xml version="1.0" encoding="UTF-8"?>
  <Faktura xmlns="http://crd.gov.pl/wzor/2025/06/25/13775/">
    <Naglowek>
      <KodFormularza kodSystemowy="FA (3)" wersjaSchemy="1-0E">FA</KodFormularza>
      <WariantFormularza>3</WariantFormularza>
      <DataWytworzeniaFa>2025-09-14T12:46:25+00:00</DataWytworzeniaFa>
    </Naglowek>
    <Podmiot1>
      <DaneIdentyfikacyjne>
        <NIP>9999999999</NIP>
        <Nazwa>Sender</Nazwa>
      </DaneIdentyfikacyjne>
      <Adres>
        <KodKraju>PL</KodKraju>
        <AdresL1>Testowa</AdresL1>
      </Adres>
    </Podmiot1>
    <Podmiot2>
      <DaneIdentyfikacyjne>
        <BrakID>1</BrakID>
      </DaneIdentyfikacyjne>
      <JST>2</JST>
      <GV>2</GV>
      <Adres>
        <KodKraju>PL</KodKraju>
        <AdresL1>Testowa</AdresL1>
      </Adres>
    </Podmiot2>
    <Fa>
      <KodWaluty>PLN</KodWaluty>
      <P_1>2022-01-01</P_1>
      <P_2>FV/2025/09/14/12/46/25</P_2>
      <P_13_1>7700.0</P_13_1>
      <P_14_1>2300.0</P_14_1>
      <P_15>10000.0</P_15>
      <Adnotacje>
        <P_16>2</P_16>
        <P_17>1</P_17>
        <P_18>2</P_18>
        <P_18A>2</P_18A>
        <Zwolnienie>
          <P_19N>1</P_19N>
        </Zwolnienie>
        <NoweSrodkiTransportu>
          <P_22N>1</P_22N>
        </NoweSrodkiTransportu>
        <P_23>1</P_23>
        <PMarzy>
          <P_PMarzyN>1</P_PMarzyN>
        </PMarzy>
      </Adnotacje>
      <RodzajFaktury>VAT</RodzajFaktury>
    </Fa>
  </Faktura>
  <Attachments>
    <base64>PHRlc3Q+amFracWbIHN0cmluZyBpa3MgZGU8L3Rlc3Q+</base64>
    <filename>nazwa pliku</filename>
    <extension>xml</extension>
    <filesize>33</filesize>
  </Attachments>
  <Attachments>
    <base64>PHRlc3Q+amFracWbIHN0cmluZyBpa3MgZGU8L3Rlc3Q+</base64>
    <filename>nazwa pliku 2</filename>
    <extension>jpg</extension>
    <filesize>33</filesize>
  </Attachments>
</invoice>

We add information about every attachment separately like this:

Copy
Copied
<Attachments>
    <base64>PHRlc3Q+amFracWbIHN0cmluZyBpa3MgZGU8L3Rlc3Q+</base64>
    <filename>nazwa pliku</filename>
    <extension>xml</extension>
    <filesize>33</filesize>
</Attachments>

Attachments are stored on A-Cube secure storage space.

Attachments can be accessed by recipient of the invoice if there is known phone number or e-mail of the recipient. Access to the attachments is possible via special link and additional authentication.

Endpoints

To find out more about attachments take a look on InvoiceAttachments API