Mario
S4hana cloud api attachment API_CV_ATTACHMENT_SRV
Mario · almost 2 years ago · Question
Answered
Mario

Hi

I am using the api to upload file to s4hana cloud, API_CV_ATTACHMENT_SRV to a supplier invoice document

in the entity /AttachmentContentset I'm trying to load 

I find an error that tells me that in the name of the file can not be empty, knowing that in the structure I am reporting the name of the file

how can I load the pdf file and convert it to base64?

and where should I report the address of the file?

----------------------------Error response from api-------------

"error": {

    "code": "SY/530",

    "message": {

      "lang": "en",

      "value": "Attachment name cannot be empty"

    },

--------------------------------------------------

the structure that I am using :

{     "DocumentInfoRecordDocType": "GOS",

        "DocumentInfoRecordDocNumber": "EXT43",

        "DocumentInfoRecordDocVersion": "",

        "DocumentInfoRecordDocPart": "",

        "LogicalDocument": "FA163E597C0",

        "ArchiveDocumentID": "FA16B72DEB7C0",

        "LinkedSAPObjectKey": "51056001902018",

        "BusinessObjectTypeName": "BUS2081",

        "SemanticObject": "",

        "WorkstationApplication": "PDF",

        "FileSize": "17408",

        "FileName": "File.pdf",

        "DocumentURL": "",

        "MimeType": "application/pdf",

        "Content": "", --------------------------------------------->>>>>>>>>>??????????????????????

        "BusinessObjectType": "BUS2081",

        "StorageCategory": "",

        "ArchiveLinkRepository": ""

      }

Comments

Comments
Alumni