Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [apex-webservice]

The tag has no usage guidance.

0
votes
1answer
26 views

SOAP Web Service Method for two top level nodes

I have a client who needs a web service method for a 3rd party to send a SOAP call to. But this soap call has two top level nodes in the body. <body> <blockOne> <data> ...
0
votes
0answers
12 views

How to retrieve files from an external server

I'm not at all that familiar with web service, but we do have this requirement in which, once a month, we need to retrieve some pdf files from a folder in an external server, and then attach them to ...
0
votes
0answers
7 views

Authenticated Callout to Webservice using SSO

We are facing the following problem. We need to make webservice callout through Mulesoft in a way the user is making the call is not a service user, but the logged one: Both Salesforce and ...
0
votes
1answer
19 views

Rest API Response - Break Address into multiple fields

I am working on an assignment where we enabled an external system to search for contacts in Salesforce based on lastName, firstName, BirthDate. I have developed a webservice which queries the Contact ...
0
votes
1answer
29 views

“Element invalid at this location” error in call to Apex web service

I am getting SessionID invalid after taking session id from visualforce page using {!$Api.Session_ID} I am getting the below response from workbench Element {https://soap.sforce.com/schemas/class/...
2
votes
0answers
36 views

Apex SOAP WebService - how to suppress/alter accepted header

I am working with a 3rd party on SOAP integration, and they send a detailed async fault response to any POST done by us. The data they send is rigid and they say they cannot (or won't) change it. I ...
0
votes
0answers
20 views

How to use the Site class outside of the context of 'Lightning Platform sites'

I am currently creating a webservice to integrate an external website to our salesforce instance. This webservice should create a new portal account user and return the id back to the calling code. I'...
2
votes
0answers
69 views

Salesforce API Integration with External Applications [closed]

What is the best way to get external Application's data on a regular interval, let's say the application am integrating has 10+ API's, all the API's data have chances of getting added/updated over ...
0
votes
2answers
404 views

How to stop Read Timed Out

So I have run a apex class that makes a callout to a external application. So I triggered the callout in SFDC and I have gotten hundreds of System Exception Read Timed Out emails. I have went to ...
-3
votes
1answer
58 views

Salesforce webservice

I developed a custom web service using Soap . The web service is supposed to send 1900+ records which satisfied the conditions in integration. When tested it only sent 1400 records and remaining are ...
0
votes
0answers
50 views

Webservice request and response for salesforce in C#

I have one web service reference added through wsdl in my C# project, this webservice have something like below updateStatus(data AS WEObject) AS WSResponse when going through the code I found these ...
1
vote
1answer
153 views

Accessing a Webservice Apex Method via SOAP-UI

So I have created a simple webservice apex class that follows the second example for webservice on this link: https://developer.salesforce.com/page/Apex_Web_Services_and_Callouts#Apex_Web_Services ...
0
votes
1answer
381 views

How to consume external webservice

I got the requirement where I need to consume the WSDL from Workday and create/update contact records in Salesforce. Can someone of you please assist me in how to utilize a WSDL from Workday into apex....
0
votes
1answer
308 views

Webservice @httpPost method authentication

Quick response on this would be helpful. I'm able to send request body from Workbench as source to my org as destination for creation of records. But what i need is how to perform the same operation ...
0
votes
1answer
133 views

The request failed with HTTP status 400: TLS 1.1 or higher required

I'm getting an error"The request failed with HTTP status 400: TLS 1.1 or higher required." on "Add Web Reference" asp.net window. Pls, help me out this.
1
vote
1answer
54 views

Inserting a record after reading XML sent by external app

External app will send XML in their request to salesforce webservice class and webservice class will have to insert a object record.I have written a webservice and it is able to get the xml in string ...
0
votes
0answers
50 views

Map key null when using getContentAsPDF() method

I have a Visualforce page that is used to generate a PDF document by our users. Recently we started experimenting with the Community License, and I'm facing an unusual error with this user. The ...
1
vote
1answer
247 views

External Data source through apex custom adapter

I want to connect the external database from salesforce. I have developed the custom adapter (DataSource.Connection class and DataSource.Provider class). In connection class, Sync method is working ...
0
votes
1answer
1k views

how to get the session Id for web service calls to salesforce

I have implemented a web service in salesforce and generated the WSDL for the web service and provided it to the external system. However while invoking a call, we need to pass the session id in teh ...
0
votes
1answer
57 views

Loading a file form sftp location into salesforce

I am working on a scenario where the file needs to be picked up from a SFTP server and loaded into salesforce. Can salesforce web service pick up a file from sftp location and load it into salesforce?...
0
votes
0answers
184 views

APEX REST Web Service: Can not deserialize: unexpected array

It is working fine in workbench but when request is coming from middleware soa it is receiving error [{"errorCode":"JSON_PARSER_ERROR","message":"Can not deserialize: unexpected array at [line:2, ...
1
vote
1answer
895 views

Authentication for custom Apex SOAP web service

I am in the process of creating a custom SOAP apex web service using webservice keyword so that external system can call this apex web service. I am not using Apex REST. From the class I can create ...
1
vote
1answer
460 views

Salesforce WeChat integration

I am relatively new to Salesforce Service console and want to integrate WeChat in Service console. If the mobile number linked to the contact is registered on we chat , I need to able to send messages ...
4
votes
1answer
313 views

How can I deprecate/remove a webservice method/class in a Managed Package?

We have completely changed the way a managed package operates and no longer want a legacy global webservice method. I don't want it to be included in future packages/installs. However, I can't seem to ...
0
votes
1answer
32 views

Checking Users credentials against AD while they are logged in

I am looking to get some suggestions on the best solution for following requirement. Any help will be appreciated. Requirement is to capture user's name using their AD credentials (they will be ...
0
votes
1answer
198 views

Execution of Javascript inside a Custom Button is deferred till the end of function

We display inside a tab in the Sales Console a custom object page layout with a custom Javascript button. Once the user clicks on that button, the custom code performs some operations on a Salesforce ...
2
votes
0answers
1k views

Trailhead Data Integration Specialist Superbadge || Test Class is Failing

I wrote the below test classes - @isTest global class ProjectCalloutServiceMock implements HttpCalloutMock{ global HttpResponse respond(HttpRequest req){ System.Debug('--++-- Inside ...
0
votes
2answers
1k views

Need build webhooks in Saleforce to recieve third party server alerts

I need some guidance/code snippet in developing a webhooks in Salesforce to receive alerts from third party server. Requirements. In our case, Insideview will send alerts to Salesforce whenever they ...
0
votes
1answer
131 views

Display status as Failure in the response of http post method

Need help in catching error message and displaying status as failure in the response, when id is not generated. Apex Code : @HttpPost global static List<SamplesResponse> doPost() { ...
0
votes
1answer
49 views

Code isn't working for a list in the post method? [closed]

What are the changes to be performed to send the list of json's, currently its working only for 1 account record. looking for the list of json as a body to pass it to salesforce. Code: @...
2
votes
3answers
199 views

Rollback changes after future Webservice call in after trigger

We are working on one web-service call in after trigger. As we can not call synchronous web-service call in trigger, we are using future call-out. But we want to rollback the changes if web-service ...
0
votes
0answers
50 views

integration from .net to salesforce, to consume data from .net to sfdc

Have a requirement to consume date from .net to sfdc, need to build web service in apex and I have shared the wsdl, but they having issue with it in .net not able to consume it. below is the class ...
0
votes
1answer
567 views

How to read XML data in salesforce?

I get data in XML from a web service from a connector URL, the xml contains data about people, now I have to read the names, emailids from that xml and compare with my org's contacts and so some ...
0
votes
2answers
2k views

how to pass JSON with Array,String [duplicate]

@RestResource(urlMapping='/v/restAPIKeyGeneration/*') global with sharing class APIforKeyGeneration{ global class Account{ public String sname; public String bp; } @...
0
votes
1answer
572 views

How to call an Apex WebService from an External System

I'm trying to build a webservice that will expose the ability to input data from an external system into salesforce. I've found multiple resources on making a webservice. I can't however find how to ...
0
votes
2answers
73 views

Getting null pointer exception in webservice class?

I am getting System.NullPointerException: Attempt to de-reference a null object Class.exposewsdl.getCaseDetailsFromcsNum: line 47, column 1 global class exposewsdl{ global class ...
0
votes
1answer
843 views

How to return fields to webservice response?

When the user enters his name from third party application, The user needs to get all the records(Account(name,Phone,email),Contact(firstname,Lastname),Lead(email,mobile number)) matching the text ...
1
vote
1answer
313 views

How to display list values in webservice class?

When the user enters his name from third party application, The user needs to get all the records(Account,Contact,Lead) matching the text entered by him. I have used sosl for this purpose.But I cant ...
0
votes
0answers
213 views

@ReadOnly thorwing System.LimitException: Too many query rows: 50001 error

I have nearly 300,000 account records in my org. I have the following class in my org: global class testReadOnly{ @ReadOnly webservice static List<Account> getAcc(){ return([...
2
votes
1answer
1k views

pass set of IDs from javascript button to a web service

I need to create a custom button on the list view of a custom object. When user selects multiple records on the list view and I need to send those record IDs to be processed by a batch process (I ...
1
vote
0answers
84 views

Web Service method over loading or default parameters

I have a web service method to load invoices into Salesforce for product type A and I am trying to modify the same method for product type B invoices. However the Product type B has couple more ...
1
vote
1answer
439 views

WebService callout failed

This Error is coming. I am wondering what could be the possible issue. I have given permission to the objects. Web service callout failed: WebService returned a SOAP Fault: INSUFFICIENT_ACCESS: ...
0
votes
1answer
240 views

What is difference between REST and SOAP Services [duplicate]

I am not able to get basic or the in depth difference, I think both are used for the same purpose so why there are two terms, I am very new to this so can anybody help me clear out the functionality ...
1
vote
0answers
114 views

Debug Logs Explanation

I'm trying to understand the debug logs Salesforce provides. There are actually two duration(in ms) for every webservice called. One at the top One at the bottom giving up split up method wise The ...
1
vote
0answers
186 views

Command button action generate dynamic CSV File and Upload into DropBox Account?

Hi All, When End User Click the Command button need to genearte the dynamic CSV File using apex and uploading into Drop Box account. Hereby my code as follows, public class ...
1
vote
1answer
243 views

Calling web service from salesforce to salesforce by using session id

I am trying to achieve to call webservice from force.com sites to salesforce providing sessionid such that i will be able to do that logic using that user see below web service global class ...
0
votes
0answers
318 views

How to handle multi callout in test class?

I have webservice class which have multi callout.For the first callout i have some list of URl's.From the list of URL's I want to do the second callout and so on. apexCode: global with sharing class ...
3
votes
2answers
322 views

Test Class Failures “Methods defined as TestMethod do not support Web service callouts” For Custom Button

I have a custom button that calls an apex class - and per this tutorial the class is a "Web Service" (but not in the classic sense). 5 days ago in production the test class (and 21 others) started to ...
1
vote
3answers
1k views

Insert/Update multiple records in salesforce using webservice

What are the possible way by which external system can insert/update multiple records in salesforce without writing any apex webservice. If webservice is required how it can be implemented. Please ...
3
votes
2answers
348 views

Salesforce - Maximum simultaneous requests callout limit

Salesforce says Maximum simultaneous requests to URLs with the same host for a callout request is 20 Statement is very simple to read but it is not very clear as to what it means. Can anyone ...