Techiio-author
Started by Jofar ArcharNov 9, 2021

Open
Use session_id from Salesforce to authenticate?

0 VIEWES 0 LIKES 0 DISLIKES SHARE
0 LIKES 0 DISLIKES 0 VIEWES SHARE

I'd like for you to make the API name from salesforce to python, after which upload some facts returned in salesforce asynchronously. Consequently, I need to log in as the authentic person in salesforce to technique my actions. As an example, an API name is made from SF to python, and then I'd like to create an account from python.

I exploit easy-salesforce in python.

I am passing the session_id from the user info.Getsessionid() from salesforce as a header in my API name to python, however then I am not able to use simple-salesforce to act because of the originating user.

How need to I accomplish that?

I have tried the following, however, I continually get invalid session_id mistakes.

from simple_salesforce import Salesforce    
Salesforce(instance_url="https://cs128.salesforce.com", session_id=session_id)
    Salesforce(instance_url="https://cs128.salesforce.com", session_id=session_id, domain='test')
    Salesforce(instance="test.salesforce.com", session_id=session_id, domain='test')
    Salesforce(instance="test.salesforce.com", session_id=session_id)

In my test, the user has a profile of system admin, with API enabled. Using my user with login/password I can successfully login to Salesforce so no problem on this site.

Just looking for a way to use the session_id from salesforce to keep on acting as the originating user.

0 Replies

You must be Logged in to reply
Trending Technologies
15
Software91
DevOps48
Frontend Development24
Backend Development20
Server Administration17
Linux Administration28
Data Center24
Sentry24
Terraform23
Ansible83
Docker70
Penetration Testing16
Kubernetes21
NGINX20
JenkinsX17
Recommended Blogs
1
Techiio-logo

Techiio is on the journey to build an ocean of technical knowledge, scouring the emerging stars in process and proffering them to the corporate world.

Follow us on:

Subscribe to get latest updates

You can unsubscribe anytime from getting updates from us
Developed and maintained by Wikiance
Developed and maintained by Wikiance