Ejemplo n.º 1
0
        public string GetOAuthURL()
        {
            // prepare the sign in URL
            Scope[]        scopes          = { Scope.DataRead };
            ThreeLeggedApi _threeLeggedApi = new ThreeLeggedApi();
            string         oauthUrl        = _threeLeggedApi.Authorize(
                CredencialService.GetAppSetting("FORGE_CLIENT_ID"),
                oAuthConstants.CODE,
                CredencialService.GetAppSetting("FORGE_CALLBACK_URL"),
                new Scope[] { Scope.DataRead, Scope.DataCreate, Scope.DataWrite, Scope.ViewablesRead });

            return(oauthUrl);
        }
Ejemplo n.º 2
0
 [Route("api/forge/clientid")] // see Web.Config FORGE_CALLBACK_URL variable
 public dynamic GetClientID()
 {
     return(new { id = CredencialService.GetAppSetting("FORGE_CLIENT_ID") });
 }