2

I have a web app that I want to allow users to create cases in Salesforce with.

Currently I have a developer instance where I call the REST api to create a case.

However, I want other people to be able to create cases through my application to their own instance.

For this to work, will they need to create an app (complex, I'd rather not require this) or is there another method, perhaps some kind of managed package, that will make it easier on the end user?

I don't want to require them to setup a complicated app and risk them having issues if they miss even one tiny step in the app creation process.

What's the best practice for something like this?

5
  • I'm just using the dev org to create the code that'll be running on the (paid) instance. Is there a better way to do this? I was under the impression that using a dev org was how you were supposed to develop your application and then move to a real instance after it's created. To stay up and up with the ToS do I need to turn this into a package of some kind? Commented Jun 29, 2015 at 19:18
  • So, you want to create an app that the paying Salesforce subscriber can install in their own org... this is exactly what the packaging (managed/unmanaged; paid/free) process is designed to deliver.
    – Mark Pond
    Commented Jun 29, 2015 at 19:24
  • Ahh, my apologies. I misunderstood your question. As Mark just posted, this is exactly what Dev Orgs are for. I thought you were asking how to replicate this type of set-up (via other Dev Orgs) to production orgs. Yes, a Dev Org is what you'd use to create a Managed Package and would be the way to distribute it to others.
    – crmprogdev
    Commented Jun 29, 2015 at 19:26
  • Yeah, basically I want to make it easy for the user to be able to use my app with salesforce. The only interaction is creating a new case. Don't need to read them or anything else. I thought just using the API would be simple for people, but the setup process is very complex for an average user. I'll look into packages more and see if that's what I need. Thanks guys. Commented Jun 29, 2015 at 19:29
  • Can you make the title here more informative? Commented Jun 29, 2015 at 21:12

1 Answer 1

0

Just use OAuth2 to provide login functionality for your app to login to salesforce.com. The first time the user logs in, it will "install" your web app as an app in their org. The administrators can then manage sessions for your app as well as user permissions within their org. See the "OAuth 2.0 Web Server Authentication Flow" for the process that this takes. Basically, you redirect their browser to a certain URL, you get a token back at your URL if they "grant access" to your app, and then you complete the token exchange. At this point, you'll have a token that lets you manipulate their org's data (not your developer org's data).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .