Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
func createAccountRequest() -> NSURLRequest {
let instanceUrl: String = SFRestAPI.sharedInstance().coordinator.credentials.instanceUrl.description
let accessToken: String = SFRestAPI.sharedInstance().coordinator.credentials.accessToken
let authUrl: String = instanceUrl + "/secur/frontdoor.jsp?sid=" + accessToken + "&retURL="
let accountUrl: String = instanceUrl + "/apex/AccountMobile?id=" + accountItem!.salesforceId!
let request: NSURL = NSURL(string:authUrl + accountUrl)!
let urlRequest: NSURLRequest = NSURLRequest(URL: request)
return urlRequest
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment