API Documentation

Get Files

Get the Physical Files

GET Command of the Files


EndpointMethodResponseExtra Info
/v1/files/FileIDGET1 fileIncludes full data and file references

Reference and Content of the Files

The FileID is the unique Reference.

Below 2 Examples:

  • Example 1 returns the minimum
    • OrderPDF : this PDF is file delivered by the supplier (if existing), otherwise it is a PDF generated by Billit
    • Attachments : one attachment, it is the XML file generated by Billit when receiving the data
{
    "OrderID": 1194146,
    "CompanyID": 588708,
    "OrderPDF": {  //Main PDF 
        "FileID": "2b5d8f7b-dd7a-4ece-adb3-d3ec7d9ff999",
        "FileName": "162121-186660-46bfc55d-be37-4d77-b5fc-578a782c9f999.xml_1.pdf"
    },
    "Attachments":
        {
            "FileID": "b049d8eb-9330-4097-be9e-c8a999f9cee9",
            "FileName": "162121-186660-46bfc55d-be37-4d77-b5fc-999a999c96f59.xml"
        }
    ],
    "OrderNumber": "QS-244SC", //number by supplier of the Invoice or Creditnote
    //.......
}
{
    "OrderID": 1555985,
    "CompanyID": 574991,
    "OrderPDF": {
        "FileID": "57eade47-f402-4605-849b-58c223c6b970",
        "FileName": "140532-206676-9688ab12-2c34-437c-808e-ee2793571c66.xml_1.pdf"
    },
    "Attachments": [
        {
            "FileID": "2690f5a8-1b49-43d1-a51d-62b8c4d08c9e",
            "FileName": "test attachment.pdf"
        },
        {
            "FileID": "1ab3b994-4883-417b-9df9-a5f2c50807fd",
            "FileName": "test attachment2.pdf"
        },
        {
            "FileID": "4163d6f0-831f-42cd-8b3d-5126f9d9fc94",
            "FileName": "test attachment3.pdf"
        },
        {
            "FileID": "943f4ea9-29ed-45e3-886c-a8a1ec108e10",
            "FileName": "140532-206676-9688ab12-2c34-437c-808e-ee2793571c66.xml"
        },
        {
            "FileID": "a311f231-d818-4088-b603-ffa590388b5a",
            "FileName": "Test Excel 1.xlsx"
        }
    ],
    "OrderNumber": "001t017"
//.......    
}

Result of GET File

{
    "FileID": "57eade47-f402-4605-849b-58c223c6b970",
    "FileName": "140532-206676-9688ab12-2c34-437c-808e-ee279999z99.xml_1.pdf",
    "MimeType": "application/pdf",
    "FileContent": "JVBERi0xLjUKJb662+4KOCAwIG9i................UgL0ltYWdlL1dpZHRoIDUxMi9IZ"
}
{
    "FileID": "57eade47-f402-4605-849b-58c223c6b999",
        "FileName": "140532-206676-9688ab12-2c34-437c-808e-ee2793579999.xml",
        "MimeType": "text/xml",
    "FileContent": "JVBERi0xLjUKJb662+4KOCAwIG9i................UgL0ltYWdlL1dpZHRoIDUxMi9IZ"
}
{
    "FileID": "57eade47-f402-4605-849b-58c223c9zb999",
    "FileName": "Test Excel 1.xlsx",
    "MimeType": "application/vnd.ms-excel",
    "FileContent": "JVBERi0xLjUKJb662+4KOCAwIG9i................UgL0ltYWdlL1dpZHRoIDUxMi9IZ"
}

How to Process a File from Base64

More info: https://docs.billit.be/docs/how-can-i-save-a-file