All Questions

Tagged with
Filter by
Sorted by
Tagged with
0
votes
0answers
23 views

JSON Parser CPU Timeout error

I have two classes that parse a json webservice callout response. One class parses a sinlge response result and the other class parses multiple response results. The primary difference between the two ...
0
votes
1answer
33 views

Custom response model in Apex not returning proper schema to LWC component

The issue I am having is that I define a custom response model in my Apex controller, and through one of the methods I populate one of the model lists with some records, then return the ...
-3
votes
0answers
19 views

Insert/Update the Salesforce Records from the SQL Server [closed]

I am new Salesforce and I am trying to understand what is the best way to Insert/update the records from the SQL server DB in to Salesforce. There is a DB view, can we directly call the DB view from ...
4
votes
1answer
58 views

Method does not exist or incorrect signature: void send(System.HttpRequest) from the type System.HttpRequest

Currently stuck at trying to send a JSON structure through web services but keep receiving the error: Method does not exist or incorrect signature: void send(System.HttpRequest) from the type System....
5
votes
1answer
84 views

Real time updates shown on record fields without user refresh

I was wondering if there is any way to show a real time update by a callout which fires, let's say an async method called from a trigger. Scenario: User updates something on the account record ...
0
votes
1answer
25 views

Response to Http request - response

I'm making integration to an external system and send them a request, and I get a JSON as a response via REST API. The response has a lot of data to upsert to SF. While upserting the Data inside the ...
0
votes
0answers
24 views

Fetching Data From Rest Web Service [duplicate]

I am new to salesforce and I followed instructions as per salesforce trailhead, https://trailhead.salesforce.com/en/content/learn/modules/apex_integration_services/apex_integration_webservices ...
1
vote
1answer
15 views

How to dynamically wait until external SOAP Web Service Return a response

I've built an external SOAP Web Service that takes several minutes to complete, I need to do some logic depending on the Service Response. Should I set a large timeOut value? Is there a way to use ...
1
vote
1answer
46 views

Run a batch after callout is finish

My process - I have a process in which I send data to outer system - and get a JSON to insert into Salesforce. This is handled by a scheduled class once a week. The Received JSON: - (Could be ~7K ...
0
votes
0answers
10 views

get mass document and related body in one webservice call

I actually want to retrieve many documents from a salesforce org to another using the salesforce API. I managed to get export the docs but the content is not return in the same webservice. Here is ...
0
votes
2answers
42 views

oAuth - how to acquire an access token from another org via an Apex callout

I want to actually connect to a salesforce environment in the background and retrieve information there. I don't want to be redirected anywhere with a token in the url. I want to be able to get the ...
0
votes
0answers
27 views

Salesforce Integrations best practice

I need to implement a request that will be sent over a 3rd party (used as tunnel) to SAP. Which mean - Request: SF --> Server 3rd Party --> SAP Response: SF <-- Server 3ed Party <-- SAP ...
0
votes
0answers
461 views

System.CalloutException: Unable to tunnel through proxy. Proxy returns “HTTP/1.1 503 Service Unavailable” ERROR

I'm trying to make an HTTP Request to other System. They provided the endpoint URL which contains a Port number. https://Test.com:50001/RESTAP/BGN/PRDV/CREATE When I'm trying to make the request I'...
1
vote
3answers
76 views

Limitation with callouts

I want to listen to the change in permissions of salesforce records. For that, I am thinking to fire a callout from an afterUpdate method of a trigger. Whenever a record is updated through any means, ...
0
votes
1answer
43 views

Connect Apex Class to a custom Screen

I have created a custom apex class that makes an HTTP POST call using callouts. Right now I have it running on a schedule using an @future method. This is working fine, but I actually want to connect ...
1
vote
1answer
33 views

Using curl to retrieve data from Apex: Where to get security token?

curl -v https://login.salesforce.com/services/oauth2/token -d "grant_type=password" -d "client_id=<your_consumer_key>" -d "client_secret=<your_consumer_secret>" -d "username=<...
0
votes
1answer
44 views

You have uncommitted work pending with the DML

public with sharing class CalloutWebservice { public Account headAccount; private Boolean ApiEnabled; private List<Account> accountList; public CalloutWebservice(ApexPages....
1
vote
2answers
80 views

WebService Post Rest API is Receiving as GET

I wrote a web service using @RestResource With both Get and Post methods. When I try to send a request via workbench - everything works great, but when I try to send a post request using other ...
1
vote
1answer
220 views

Enabling State and Country/Territory Picklists

Currently we are using text field to store state and country. Now we want to enable State and Country/Territory Picklists to maintain data quality in salesforce. If I enable the picklist, what all ...
2
votes
1answer
71 views

Enterprise Patterns for Consuming non-trivial REST services in Apex [closed]

Communication from Apex with huge REST Apis feels cumbersome to me as there is so much repetitive work involved with building Apex Objects that function as callout request params or responses. This ...
2
votes
0answers
165 views

Is it possible to download archived contentversion or contentDocument

I am having a hard time downloading a contentversion/contentdocument where contentdocument is already archived. I am trying to download the file by hitting rest endpoint services/data/v44.0/...
5
votes
1answer
177 views

Custom Webservice class design

My client wants to send Account and Contact information from external system. For that reason, I have created one custom webservice class which can take any kind of data and based on the structure of ...
0
votes
0answers
39 views

Call a field inside a class dynamically

I have a JSON that I get as a webservice and deserialize it into classes. The classes are : public class DataStructure{ public String Name; public String Code; public String ...
0
votes
1answer
60 views

How to Retrieve large data from Salesforce using Rest API?

I have one new requirement where My client wants to retrieve large data set (~80K records) from Salesforce daily. I have created rest web service but it returns only 2k records. for 80k records, do ...
0
votes
1answer
259 views

Authentication Token with apex

I want generate a token, give this token to third-party application, and this app can authentificate into salesforce and call the web service. I want to create an authentication token, call a third ...
1
vote
1answer
200 views

Understanding authentication for Apex SOAP web service

I have read this post: How authentication works in APEX and since the SF documentation is a bit confusing for me at this point I would like to ask: Is it possible to get the session id with a ...
0
votes
2answers
31 views

Import data from local machine to custom object

I have a requirement to import data from local machine(user placed .csv files in a common location) to the custom object with out user interference on hourly basis.could you please give suggestions to ...
2
votes
0answers
59 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
1answer
92 views

Search Value inside a picklist before inserting

I have objects that I need to fill from a web service that I get from some source. I wondering, If I want to check if a picklist value that transferred from this webservice is a valid value in the ...
1
vote
1answer
46 views

Can't convert WSDL into Apex Class

I'm trying to convert an Apex from a WSDL file, but I'm struggling with it. Since I'm not an experienced developer, the solution may be very simple and I hope anyone can help me. When I try to ...
0
votes
1answer
51 views

Is it possible to get XML version of Standard Object

We have an Informatica job which runs every night that extracts Salesforce data and loads into MDM. We recently changed an Opportunity field name and my colleague need to synchronize the change with ...
1
vote
1answer
92 views

Optional webService parameter in apex

I have a apex webservice with "data structure" made of webService attributes. In request data, i have: global class GetRequestData{ webService Date From; webService Date To; webService ...
8
votes
2answers
728 views

Metadata API error while reading Picklist: Web service callout failed: Unable to find apex schema info

I am trying to read a custom dependent picklist field and update it's field-dependencies. I have followed the common resources found online and getting the below error: FATAL_ERROR System....
9
votes
2answers
398 views

Tooling API in Apex - polymorphism, generic query() callout?

I am working on Salesforce project heavily depending on use of Tooling API (we are executing tests on remote SF organizations and gathering results). What bothers me is I cannot use polymporphism ...
1
vote
1answer
44 views

How to call a web service with base85 encoded data?

I need to make a call to a 3rd party SOAP web service from Apex that accepts images encoded in base85 rather than the more standard base64. I don't see that this is supported in Salesforce, any ideas ...
2
votes
1answer
117 views

When using WSDL2Apex, CDATA tags in WebserviceCallout are encoded

I need to implement a SOAP Request as WebServiceCallout which includes CDATA tags in its request envelope. The marshaller class has been auto-generated and the request is working just fine except that ...
2
votes
3answers
160 views

Test for Apex class that creates a custom field

I have an apex class that creates a custom field on an sObject via an HttpRequest and I'm not sure how to write a test for this because one of the things I need to test is that the field has the ...
0
votes
1answer
2k views

Unexpected character ('a' (code 97)): expected a valid value (number, String, array, object, 'true', 'false' or 'null') at input location [1,2]

I have a batch class which makes a call out to an api within the same org (the rest resource was developed by a 3rd party supplier and I cannot see its source code) Anyway, as per the supplier the ...
0
votes
0answers
497 views

AMQP protocol from Apex - RabbitMQ

I am trying to connect and send data to RAbbit MQ messaging protocol. At all places it is provided that we should use AMQP protocol and this is something I am not sure how to do from Apex. Has anyone ...
0
votes
1answer
45 views

Web Service call to Service Cloude [closed]

I have a trigger that is ultimately going to send a mailing in Marketing Cloud when triggered from Service Cloud. This request will need to be two requests, one to get an auth token and a second using ...
0
votes
1answer
49 views

Is there any dummy Bank data available online which I can use to bank a simple bank application in salesforce

I want to integrate a bank with my salesforce. Is there any online dummy bank whose data I can use to integrate it with my salesforce. My Requirements :- I have a bank whose web services are ...
0
votes
0answers
78 views

Search and view data from external database

I have a business requirement to create a way for users to search and view results from an external database (Snowflake) in Salesforce. I have created a simple visualforce page and need to send a ...
0
votes
1answer
29 views

how to get responce from url webservice

I have made a webservice to match a phone number and want to return the id of the record. When I test this in workbench this works and have a match. I have a public site with a public class where I ...
1
vote
2answers
382 views

Does an update called in an @future method count as being in the same transaction as the method that called it?

I am on occasion seeing a "You have uncommitted work pending. Please commit or rollback before calling out" error during a sequence of callouts that are part of the same transaction. So basically the ...
1
vote
0answers
50 views

Pushing a git repository to a Sandbox via a PostCopy script

I am currently trying to automate the whole process for working with Sandboxes in my company. As of now, we have a CLI tool which both refreshes the sandboxes and executes an Apex anonymous script to ...
0
votes
0answers
62 views

How to consume OAuth 1.0 webservice in salesforce

I have another application which I need to call and they are using OAuth 1.0. now I am calling their system endpoint, I have client id and client secret only. Do I need to generate token also? ...
0
votes
1answer
792 views

How to use JSON class as a inner class instead of seprate class

Main Class: @RestResource(urlMapping='/cases/*') global with sharing class InsertCaseHelper { global static string responsePayLoad; @HTTPPOST global static void insertCase(){ ...
0
votes
1answer
27 views

Incorrect signature on Rest api unittest

I have made a (POST) webservice. I am trying to write a unittest but keep getting the error incorrect signature: void createInvoice() from the type InvoiceManager before I can save my class, what am i ...
0
votes
1answer
664 views

Illegal assignment from void to String

I am trying to save my test class for a Rest a webservice (GET) but get the error Illegal assignment from void to String on line 16. If I change the void to string I get a missing return statement ...
-1
votes
1answer
28 views

How to create an external databate to test rest API classes

I have been doing some trailheads for REST api's I managed to create a callout class with a mock response based on a static resource, whitch gives me 100% coverage. I would like to see my Callout in ...