cancel
Showing results for 
Search instead for 
Did you mean: 

How to read user given file using custom endpoint in CAP Node.js

rupambecs999
Explorer

I'm looking to utilize a custom endpoint for file uploading and reading, intending to not store the file in my database. Although I've attempted the following approach, I encountered an error that states, "No payload deserializer available for resource kind 'ACTION_PARAMETERS' and mime type 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'." What is wrong here or how read the file?

CDS File:

JS File:

View Entire Topic
vansyckel
Advisor
Advisor
0 Kudos

Hi Rupam,

OData actions only accept application/json.

Either follow our guide on Media Data or prepend the OData protocol adapter in a custom server.js.

Best,
Sebastian