Foretagsplatsen.Api2.OAuthService.CreateSession C# (CSharp) Метод

CreateSession() публичный статический Метод

public static CreateSession ( OAuthCredentials credentials, string oAuthBaseUrl, string callbackUrl ) : IOAuthSession
credentials OAuthCredentials
oAuthBaseUrl string
callbackUrl string
Результат IOAuthSession
        public static IOAuthSession CreateSession(OAuthCredentials credentials, string oAuthBaseUrl, string callbackUrl)
        {
            var consumerContext = new OAuthConsumerContext
            {
                ConsumerKey = credentials.ConsumerKey,
                ConsumerSecret = credentials.ConsumerSecret
            };

            return new OAuthSession(
                consumerContext,
                GetRequestTokenEndpointUrl(oAuthBaseUrl),
                GetAuthorizeEndpointUrl(oAuthBaseUrl),
                GetAccessTokenEndpointUrl(oAuthBaseUrl),
                callbackUrl);
        }