jesperfj / force-rest-api

Java library for Force.com REST API
135 stars 114 forks source link

Missing instance_url and id in ApiSession #70

Open xgp opened 6 years ago

xgp commented 6 years ago

According to https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/intro_understanding_web_server_oauth_flow.htm the instance_url and id are returned when a request is made for an access token in exchange for an authorization code (your Auth.completeOAuthWebServerFlow method that returns an ApiSession). Is it possible to add those fields to ApiSession? Would you accept a PR that does this? Thanks!

xgp commented 6 years ago

https://github.com/jesperfj/force-rest-api/pull/71

jesperfj commented 3 years ago

instance_url is available in ApiSession.getApiEndpoint(). id is not currently available but I believe it's just a pointer to the same resource as what you get with ForceApi.getIdentity(). Can you confirm?