Hi Shreyank, This is the github link: https://github.com/DanCarl857/Mobile-Application/tree/master/frontend-app
Thanks Cheers! Daniel Carlson On Tue, Jul 12, 2016 at 10:07 AM, Shreyaank Byadagi < shreya...@confluxtechnologies.com> wrote: > Hi Daniel, > Please share your code I will look into your code base and try to fix it > > Regards > Shreyaank > > On Tue, Jul 12, 2016 at 1:01 PM, Daniel Carlson <dancarl...@gmail.com> > wrote: > > > Hi Shreyaank, > > > > But when I use that from within my code. Like for example when the user > > logs in, they enter their username and password(in this case mifos and > > password), I want to use this to log them onto the mifos platform so I > use > > that call from within my code. But I am getting CORS errors. I had to > > download and add a plugin in Chrome which enables that. Could you tell > how > > to fix this so that it works on all browsers? This is because clients > with > > Chrome may not have this plugin. > > > > Cheers! > > Daniel Carlson > > > > On Tue, Jul 12, 2016 at 8:07 AM, Daniel Carlson <dancarl...@gmail.com> > > wrote: > > > > > Hi Nikhil, Terence, > > > > > > I wanted to do this from within the code as it is part of the login > > > service for my app. > > > > > > Terence that solved it thanks. Many heads are indeed better than one. > > > > > > Cheers! > > > Daniel Carlson > > > > > > > > > On Tue, Jul 12, 2016 at 7:51 AM, Nikhil Pawar <nickr...@gmail.com> > > wrote: > > > > > >> Hey Daniel, > > >> > > >> Need not pass username and password as query parameter.(its not GET > > >> method) > > >> Try this: > > >> > > >> > > > https://localhost:8443/fineract-provider/api/v1/offices?tenantIdentifier=default > > >> > > >> and then you will be asked for username and password. > > >> > > >> You can also use clients like Postman for chrome or RESTClient for > > mozilla > > >> for testing of REST API. > > >> > > >> Regards, > > >> Nikhil > > >> > > >> On Tue, Jul 12, 2016 at 12:06 PM, Daniel Carlson < > dancarl...@gmail.com> > > >> wrote: > > >> > > >> > Hi Terence, > > >> > > > >> > Thanks but I already tried that. > > >> > > > >> > Cheers! > > >> > Daniel Carlson > > >> > > > >> > On Tue, Jul 12, 2016 at 7:34 AM, Terence Monteiro < > > >> > tere...@sanjosesolutions.in> wrote: > > >> > > > >> > > Hi Daniel, > > >> > > > > >> > > The URL you used needs to have username=mifos&password=password so > > >> remove > > >> > > the extra %22 codes and try. > > >> > > > > >> > > -- > > >> > > Best Regards, > > >> > > Terence Monteiro, > > >> > > Mob: +91 96633 13728 > > >> > > www.sanjosesol.com > > >> > > > > >> > > <http://goog_1610728024> > > >> > > "Providence", No. 36, > > >> > > Ahmed Sait Road, > > >> > > Frazer Town, Bangalore - 5. > > >> > > > > >> > > On Tue, Jul 12, 2016 at 10:46 AM, Daniel Carlson < > > >> dancarl...@gmail.com> > > >> > > wrote: > > >> > > > > >> > > > Hi, > > >> > > > > > >> > > > I already have those. > > >> > > > When I use my local server, after installing a plugin to enable > > >> CORS, I > > >> > > get > > >> > > > a 500 error code > > >> > > > I am using this link locally: > > >> > > > > > >> > > > > > >> > > > > >> > > > >> > > > https://localhost:8443/fineract-provider/api/authentication?username=%22mifos%22&password=%22password%22&tenantIdentifier=default > > >> > > > That is the link from within my code > > >> > > > > > >> > > > And when I try to connect to the online server using this: > > >> > > > > > >> > > > > > >> > > > > >> > > > >> > > > https://demo.openmf.org/fineract-provider/api/authentication?username=%22mifos%22&password=%22password%22&tenantIdentifier=default > > >> > > > > > >> > > > I get a 401 which tells unauthorized but I just used the mifos > and > > >> > > password > > >> > > > credentials to login. > > >> > > > > > >> > > > Cheers! > > >> > > > Daniel Carlson > > >> > > > > > >> > > > On Tue, Jul 12, 2016 at 6:03 AM, Shreyaank Byadagi < > > >> > > > shreya...@confluxtechnologies.com> wrote: > > >> > > > > > >> > > > > Hi Daniel , > > >> > > > > > > >> > > > > please add following headers in REST client > > >> > > "Fineract-Platform-TenantId: > > >> > > > > default" and "Content-Type: application/Json" > > >> > > > > > > >> > > > > Regards > > >> > > > > Shreyaank > > >> > > > > On 12-Jul-2016 10:29 AM, "Shreyaank Byadagi" < > > >> > > > > shreya...@confluxtechnologies.com> wrote: > > >> > > > > > > >> > > > > > Hi Daniel, > > >> > > > > > To which server your communicating ? Demo server or local > > server > > >> > > > > > > > >> > > > > > Regards > > >> > > > > > Shreyaank > > >> > > > > > On 12-Jul-2016 10:01 AM, "Daniel Carlson" < > > dancarl...@gmail.com > > >> > > > >> > > > wrote: > > >> > > > > > > > >> > > > > >> Hi all, > > >> > > > > >> > > >> > > > > >> For my Google Summer of Code project for this year, I need > to > > >> get > > >> > > data > > >> > > > > >> from > > >> > > > > >> the Mifos platform. To that, according to the REST API > > >> > > documentation, > > >> > > > I > > >> > > > > >> have to authenticate that request by by using a basic > > >> > authentication > > >> > > > key > > >> > > > > >> which I then used to make my requests. > > >> > > > > >> I have used this link: > > >> > > > > >> > > >> > > > > >> > > >> > > > > > > >> > > > > > >> > > > > >> > > > >> > > > https://demo.openmf.org/fineract-provider/api/authentication?username=mifos&password=password&&tenantIdentifier=default > > >> > > > > >> > > >> > > > > >> but I get CORS errors despite my header configurations > which > > I > > >> > > copied > > >> > > > > from > > >> > > > > >> the community app. > > >> > > > > >> So I setup my local server and used this link: > > >> > > > > >> > > >> > > > > >> > > >> > > > > > > >> > > > > > >> > > > > >> > > > >> > > > https://localhost:8443/fineract-provider/api/authentication?username=mifos&password=password&&tenantIdentifier=default > > >> > > > > >> > > >> > > > > >> Now I get a 500 error code on Firefox and on Chrome I still > > >> get a > > >> > > CORS > > >> > > > > >> error > > >> > > > > >> > > >> > > > > >> Any help with this please? > > >> > > > > >> > > >> > > > > >> Cheers! > > >> > > > > >> Daniel Carlson > > >> > > > > >> > > >> > > > > > > > >> > > > > > > >> > > > > > >> > > > > >> > > > >> > > > > > > > > > > > > -- > Thanks and Regards > Shreyaank > E-mail:shreya...@confluxtechnologies.com >