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 [rest-api]

REpresentational State Transfer (REST), or RESTful, web services provide interoperability between computer systems on the Internet. The Salesforce REST API provides a powerful, convenient, and simple Web services API for interacting with Force.com.

0
votes
2answers
94 views

Custom Activity in Journey Builder Slowing Down Performance

We are using a custom activity (Urban Airship integration) that sends push notifications to our customers. The Custom Activity is hosted on AWS. We are seeing a throughput of about 6-10 emails per ...
0
votes
0answers
123 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 ...
2
votes
0answers
32 views

Cannot insert Contact with REST API if a Lead with the same e-mail address exists

I noticed in the UI that when I try to insert a contact with an e-mail address that a lead already has, I get a warning (before I click save and insert the contact) saying that this is a possible ...
0
votes
0answers
42 views

How To Track API Calls Into Org?

I want to monitor within SFDC any api calls that are made at the call level to my org from external applications. I'd like to know which app is making them and what data they're GET/POSTing. Is this ...
0
votes
0answers
26 views

How to get pardot's prospects back up into salesforce's custom object using pardot api

I have requirement where I need to backup all the pardot propects from pardot to salesforce's custom object. Is there easy way to do it ?
0
votes
1answer
329 views

Delete multiple records using REST Api

I am trying to delete multiple records using REST Api. using below url https://xxx.salesforce.com/v43.0/composite/sobjects?ids=00P0K000016YabaUAG,00P0K000016YabaUAG but in response I am getting 405 ...
-1
votes
1answer
52 views

How to add duplicate fields in list in JSON deserialize method?

I need to parse this JSON and store services in a list but getting exception in deserialize due to duplicate field. Can someone help what I need to change to make this work? I have generated the class ...
0
votes
2answers
160 views

Rest callout via Batch Apex throws invalid session Id error

My Question is exactly same as this one - https://developer.salesforce.com/forums/?id=9060G0000005MLWQA2 But i will give more details. We just turned on Lightning Knowledge on in our environment, ...
1
vote
2answers
148 views

Getting null for inner classes in complex JSON deserialization

I am trying to parse a nested JSON and have generated the apex code using JSON2Apex as below: global with sharing Class ServiceUpdates { @HttpPost global static void updateservice()...
0
votes
1answer
34 views

How to find the mandatory fields on Sobjects in RestAPI /describe

I am trying to create an oAuth based app that integrates with salesforce to create the objects from the app. To let users know what all fields that users needs to put in at minimum to create the ...
0
votes
1answer
114 views

run automation SOAP API

I have created a automation with script activity which i need to run it through SOAP API. when i pass the payload i get a response as 200 ok but the automation is not running. Below is the payload.<...
1
vote
0answers
46 views

Is it possible to unsubscribe a user using a rest API?

I would like to unsubscribe a user using a Rest and not SOAP API, do you know if this is possible? Thanks, Felipe
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
0answers
55 views

Composite Resource to Insert ContentVersion giving Unusual Response

I am using below code to insert File using Composite Resource: saveFile: function(component, fileName, base64, recordId ) { var path = '/services/data/v43.0'; var conn = new jsforce....
2
votes
1answer
168 views

validateEmail REST Api call through Ampscript

I'm trying to validate an email in a cloud page using ampscript REST API Call but the httppost always returns me the 401 error. I managed to call the accessToken just fine, but there is probably some ...
0
votes
0answers
64 views

update multiple data extension in real time

we have a 3rd party tool which is sending us XML data using the rest api endpoints and it gets stored in the data extension, now, there are 10 more data extension which needs to be populated based on ...
1
vote
2answers
363 views

a way to return value from @future method

I have a situation where I have to insert data into a wrapper class and a bunch of objects to save in Salesforce first and then make an API call. As we know, salesforce will not allow us to make any ...
0
votes
1answer
253 views

Create leads in Salesforce through REST API. How to assign assignmentruleHeader and emailHeader?

I am trying to add leads in salesforce through rest API.Code is in java. I have converted WSDL to jar files and added as reference in Eclipse which allow to access salesforce objects in java. PFB my ...
0
votes
2answers
29 views

Unable to convert phone to string in apex

I am working on rest API services. I need to push phone number as a string in the body of the request. I tried following way. String Str1=ts.phone.replaceAll('(',''); String Str2=Str1.replaceAll(')',...
1
vote
0answers
69 views

REST API - Retrieve Data Extension through Campaign

I am trying to use the REST API to find a Data Extension External Key through the Campaign ID that is associated with the Data Extension. When running the call: https://www.exacttargetapis.com/hub/v1/...
1
vote
2answers
66 views

Not able to filter all running journeys via Marketing cloud API

I am trying to view all journeys with Published status(if current version is draft then previous published version) but not able to do so as list of all journeys is returned. curl -X GET \ https://...
0
votes
1answer
20 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
1answer
113 views

Invoke Rest Service from Visualforce page

I have a VF page that tries to invoke REST API from within script. On button click I am getting error: No 'Access-Control-Allow-Origin' header is present on the requested resource. I am specifically ...
0
votes
0answers
36 views

forcetk restapi broken in visualforce page (not in lighting container)

The following code was working fine until few months back, but now it is broken and giving an error as below: var params = { 'Type': 'Folders' }; var forcetkClient = new forcetk.Client(); ...
0
votes
1answer
144 views

Post request returns error 405 on ngrok

I'm using ngrok in order to tunnel localhost and check my REST request from Salesforce. However, when I send POST request I get error 405 - method not allowed. Below there is my code: HttpRequest ...
0
votes
2answers
77 views

RestResource HttpPost - 401 Unauthorized - INVALID_SESSION_ID

I am attempting to call a RestResource HttpPost method, but receive an INVALID_SESSION_ID response. [{"message":"Session expired or invalid","errorCode":"INVALID_SESSION_ID"}] Apex Code (version 43):...
0
votes
0answers
22 views

Is there a concurrent API limit on calls to /login/salesforce/authorize

Our Application is iFramed and we have implemented Salesforce SSO using web flow we have implemented 4 iframe component of our application and these components lie under the accounts in the cusotmer ...
0
votes
0answers
22 views

ClassCastException on APIObject to DataExtensionObject when we upgraded to java 8

When we switched from a java 6 to java 8 application server environment we got this runtime ClassCastException when we call the MC API java.lang.ClassCastException: hbs.schoolwide.hbsMessaging....
0
votes
1answer
83 views

Create Installed Package Into Business Unit (Account) Via API

We are moving from the old SOAP API to the new REST API to publish into Content Builder. As a result we need to create installed packages inside our clients SFMC accounts so we can get tokens to use ...
1
vote
1answer
143 views

Not able to authenticate aws from apex

Below is the code I'm running from apex execute. Error received - signature mismatch error... Able to authenticate using postman String formattedDateString = Datetime.now().formatgmt('yyyyMMdd\'T\'...
2
votes
1answer
78 views

no response when calling rest api from javascript function

i have two org, first org i have written code for GET method, Second org i am calling a the rest api GET method from javascipt code. in the calling org i dont get any response but it response with ...
0
votes
2answers
125 views

Marketing Cloud sending Content Builder Email to List

I have created a list (using SOAP API) and know the ID of this. The HTML Email exists in Content Builder, I know the name and the ID. How can I send the email to the list. This is not a triggered ...
0
votes
1answer
321 views

Status Returned 200 but response body is blank

I'm new to integration. I am going to generate an access token for the third-party application. I tried to build following javascript request in sfdc. But the response body is blank. I need to ...
0
votes
1answer
337 views

How to Generate Access token in rest api with apex [closed]

I'm new to integration. I want to post a field value to other external application. So, the third party is using OAuth 2.0 Security. I'm going to generate access token through client key. They ...
1
vote
1answer
84 views

Salesforce Bulk APi Session Id

I have used the salesforce REST API a ton in the past, but I am at the point where I need more speed for fetching/inserting/updating a large number of records at once. I have a remote application ...
0
votes
0answers
19 views

Is it possible to search Task or Event(activities) with parameterizedSearch REST API?

I'm using this endpoint /vXX.X/parameterizedSearch/?q=search string, it works ok except, it doesn't work for Task and Event. I have this error: errorMsg: "sObject type 'Event' is not supported in ...
2
votes
3answers
225 views

Getting JSON_PARSER_ERROR while parsing JSON

What am i doing wrong due to which i am getting JSON_PARSER_ERROR, I am using code below to parse json below : @RestResource(urlMapping='/Imbellus/CandidateScore') global with sharing class ...
0
votes
1answer
72 views

DELETE Dependencies REST API DELETE_FAILED

When attempting to use REST API to delete multiple object records like so: h t t p s://org.my.salesforce.com/services/data/v42.0/composite/sobjects?ids=0010x000000000,a1r0x000000001,a1m0x000000002,...
0
votes
2answers
360 views

Need to pass Field api name and its value in API call using field set [closed]

Need to make the requested body for Rest POST call in which key(API name) and value both go dynamically in JSON format. API name comes from field set and its value come from the database using query. ...
0
votes
0answers
21 views

Can I update multiple currencies in a single Rest Call?

I need to update our currencies and doing that via a REST call, been initiated by an Apex class. Is it possible to update all my currencies in a single call? I have based my solution on the ...
0
votes
1answer
45 views

Connect to SFMC accounts via REST API with Username and Password - Not Key

I work at a software company that pushes emails from our app into SFMC. We were using the old SOAP API to connect to client accounts previously, but this is being deprecated and we need to push to ...
1
vote
0answers
26 views

Unable to set Null to any dateType field to Salesforce using Force.com

I have tried the below code. This works when I assign some valid date to the field (of Date Type), but unable to set null to it : var auth = new AuthenticationClient(); await auth....
0
votes
0answers
41 views

Get more then 2000 records in listview API

My Contact Listview has 5000 records and I want to get all the records using Listview API . I can use offset upto 2000 which means I can query 4000 in total . Is there any other way I can get all 5000 ...
2
votes
1answer
61 views

Ramdom failure on https://login.salesforce.com/services/oauth2/token request

I am connecting with the Salesforce API using OAuth, refresh_token, client_id & client_secret. API calls are failing randomly with, it's not every API call but 1 in 100 or sometime in 1000 will ...
0
votes
2answers
206 views

Clear platform event limits?

Where can I find clear docs on the API limits for sending platform events IN to sfdc? The platform events basics trailhead notes that: provides allocations for how many events you can define in ...
1
vote
1answer
74 views

External user upload file

We're trying to allow Customer Community Users to upload files using our portal. When I try to use the REST API to upload a file I get a 403 Forbidden response. The response body has message":"API is ...
1
vote
1answer
45 views

How do i check if a user logged into salesforce from javascript? Either through api or reading cookie value [closed]

We want to allow users who are already logged into salesforce and have access to our application to continue to our application home page without going through the login flow , if not we want to take ...
2
votes
1answer
463 views

How to properly handle dates returned from REST API

So it appears that when returning a DATE field from the REST API, that salesforce does NOT convert it to UTC (Doesn't return any time-zone information, just a YYYY-MM-DD string. Instead it returns ...
4
votes
1answer
81 views

HealthCloud HL7 REST API Specification

I'm working to implement HealthCloud with an external system. HealthCloud provides the services/apexrest/HealthCloudGA/HL7 REST endpoint to accept HL7 messages and parse them into the Electronic ...
0
votes
0answers
31 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 ...