On Tue, Apr 28, 2015 at 2:16 PM, Dulitha Wijewantha <[email protected]>
wrote:

> Yeah, that's the service URL to get tokens, but I am looking for an api to
> get the tokens. Since there is no such API available, shall I improve the
> oAuth module to perform this function?
>
+1, but don't couple it into any API Manager specific codes. If you have to
do so, then come up with a new module.

>
> On Fri, Apr 24, 2015 at 7:33 PM, Madusanka Premaratne <[email protected]
> > wrote:
>
>> Hi Dulitha,
>> You can call to https://localhost:8243/token to get both refresh_token
>> and access_token
>> Have a look at the following curl command
>> curl -k -d "grant_type=password&username=admin&password=admin" -H
>> "Authorization: Basic
>> bmU5X015dDNKWGxuTDRNWjhrbnlFdDM3cGRvYTpTSEtCOTZoX0RjeGVlMnQ0eG9JZlhMUERRRHdh,
>> Content-Type: application/x-www-form-urlencoded"
>> https://localhost:8243/token
>>
>> Thanks,
>> Madusanka
>>
>> On Fri, Apr 24, 2015 at 5:14 PM, Dulitha Wijewantha <[email protected]>
>> wrote:
>>
>>> Hi guys,
>>> Is there are any available module for jaggery (or Java) that can be
>>> called to obtain oAuth 2 tokens from API Manager? I looked into the oauth
>>> module [1] in jaggery but it doesn't seem to return refresh tokens.
>>>
>>> My use-case is to obtain access/refresh tokens for Password/SAML Grant
>>> Type from a Jaggery app.
>>>
>>> [1] -
>>> https://github.com/wso2/jaggery-extensions/blob/master/oauth/resources/org.jaggeryjs.modules.oauth/src/main/java/org/jaggeryjs/modules/oauth/OAuthHostObject.java
>>>
>>> Cheers~
>>>
>>> --
>>> Dulitha Wijewantha (Chan)
>>> Software Engineer - Mobile Development
>>> WSO2 Inc
>>> Lean.Enterprise.Middleware
>>>  * ~Email       [email protected] <[email protected]>*
>>> *  ~Mobile     +94712112165 <%2B94712112165>*
>>> *  ~Website   dulitha.me <http://dulitha.me>*
>>> *  ~Twitter     @dulitharw <https://twitter.com/dulitharw>*
>>>   *~Github     @dulichan <https://github.com/dulichan>*
>>>   *~SO     @chan <http://stackoverflow.com/users/813471/chan>*
>>>
>>> _______________________________________________
>>> Dev mailing list
>>> [email protected]
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> *Madusanka Premaratne* | Associate Software Engineer
>> WSO2, Inc | lean. enterprise. middleware.
>> #20, Palm Grove, Colombo 03, Sri Lanka
>> Mobile: +94 71 835 70 73| Work: +94 112 145 345
>> Email: [email protected] | Web: www.wso2.com
>>
>> [image: Facebook] <https://www.facebook.com/maduzanka> [image: Twitter]
>> <https://twitter.com/rmmpremaratne> [image: Google Plus]
>> <https://plus.google.com/u/0/+MadusankaPremaratnemaduz/about/p/pub> [image:
>> Linkedin] <http://lk.linkedin.com/in/madusanka/> [image: Instagram]
>> <http://instagram.com/madusankapremaratne> [image: Skype]
>> <http://@rmmpremaratne>
>>
>>
>
>
> --
> Dulitha Wijewantha (Chan)
> Software Engineer - Mobile Development
> WSO2 Inc
> Lean.Enterprise.Middleware
>  * ~Email       [email protected] <[email protected]>*
> *  ~Mobile     +94712112165 <%2B94712112165>*
> *  ~Website   dulitha.me <http://dulitha.me>*
> *  ~Twitter     @dulitharw <https://twitter.com/dulitharw>*
>   *~Github     @dulichan <https://github.com/dulichan>*
>   *~SO     @chan <http://stackoverflow.com/users/813471/chan>*
>



-- 

*Ruchira Wageesha**Technical Lead*
*WSO2 Inc. - lean . enterprise . middleware |  wso2.com <http://wso2.com>*

*email: [email protected] <[email protected]>,   blog:
ruchirawageesha.blogspot.com <http://ruchirawageesha.blogspot.com>,
mobile: +94 77 5493444*
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to