Salesforce client for an Apex RESTful web service

Expose a Rest service from an Apex class using RestResource annotation

Aug 29, 2020
featured image

An example about how to consume a Salesforce api rest, for instance:


The example shows how to authenticate using username and password to get the access token and then how to do a request to this Salesforce web service:

global class HelloRest {

    global static String echo(String name) {
        String echo = 'Hi, '+name;
        System.debug('Echo: '+echo);
        return echo;

See the code from Github

salesforce apex dev