Skip to content

Instantly share code, notes, and snippets.

@jkentjnr
Created March 16, 2015 04:47
Show Gist options
  • Save jkentjnr/46b280737dd7d289955a to your computer and use it in GitHub Desktop.
Save jkentjnr/46b280737dd7d289955a to your computer and use it in GitHub Desktop.
Get Salesforce Instance URL using Apex
// Get Current SFDC Instance URL
// For example: AP1 = 'https://ap1.salesforce.com
URL.getSalesforceBaseUrl().toExternalForm();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment