Last active
August 7, 2018 04:27
-
-
Save Naveendhanaraj/54189e67c7e78ba8233c0060ace53000 to your computer and use it in GitHub Desktop.
Get Refresh Token by giving Consumer Secret and Consumer Key
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<apex:page controller="RefreshTokenClass" > | |
<apex:slds /> | |
<apex:form > | |
<div class="slds-form slds-form_stacked"> | |
<div class="slds-form-element slds-size_2-of-4"> | |
<label class="slds-form-element__label" for="input-id-01"><b>Client Id</b></label> | |
<div class="slds-form-element__control"> | |
<apex:inputText id="clienti" styleClass="slds-input" value="{!clientid}"/> | |
</div> | |
</div> | |
<div class="slds-form-element slds-size_2-of-4"> | |
<label class="slds-form-element__label" for="input-id-01"><b>Client Secret</b></label> | |
<div class="slds-form-element__control"> | |
<apex:inputText id="clientsecr" styleclass="slds-input" value="{!clientsecret}" /> | |
</div> | |
</div> | |
</div> | |
<br/> | |
<apex:commandButton action="{!auth_step_1}" value="Step1:Get Authorization Code"/> | |
<apex:commandButton action="{!auth_step_2}" value="Step2:Get RefreshToken"/> | |
<br/> | |
<div style="display:{!IF($CurrentPage.parameters.code != Null && str = Null ,'block','none')}"> | |
<label><b>Authorization Code:</b></label> | |
<div class="slds-page-header slds-p-top_medium"> | |
<b>{!$CurrentPage.parameters.code}</b> | |
</div> | |
</div> | |
<div style="display:{!IF(str = Null, 'none','block')}"> | |
<label><b>Refresh Token:</b></label> | |
<div class="slds-page-header slds-p-top_medium" style="display:{!IF(str = Null,'none','block')}"> | |
<b>{!str}</b> | |
</div> | |
</div> | |
</apex:form> | |
</apex:page> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment