Activity Forums Salesforce® Discussions How to get csv file in a web service post method in Salesforce?

  • Aman

    Member
    August 10, 2017 at 1:41 pm

    Hello Shariq,

    you can try this :

    @RestResource(urlMapping='/contactCsv/*')
    global class RESTContactController {
    @HttpPost
    global static void newContacts(){
    RestRequest req = RestContext.request;
    System.debug('csv'+req);
    }
    }

  • Parul

    Member
    September 16, 2018 at 1:19 pm

    Hi

    @RestResource(urlMapping='/accountCsv/')

    global class REST ContactController{

    @HttpPost

    global static void newAccounts(){
    RestRequest req = RestContext.request;
    System.debug(‘csv’+req);

    }}

     

    Thanks

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos