How to integrate Instamojo payment gateway in laravel 4.2? - laravel-4

I have done it in case of paypal.
Is there any way to integrate instamojo like this?
"require": {
"laravel/framework": "4.2.*",
"moltin/laravel-cart": "dev-master",
"paypal/rest-api-sdk-php": "*"
}

Laravel has a package called Indian Payment Gateway (indipay) by which you can configure payment gateways like CCAvenue, PayUMoney, EBS, CitrusPay, Instamojo recently I have used this package for the integration and succeeded. The below link has a clear steps to do the integration process.
Github link

Related

Login with Linkedin shows error "The Application is disabled" Laravel

I'm integrating LinkedIn with socialite in laravel
I got this error when logging in with LinkedIn "The application is disabled". Can you help identify the issue if ever I missed something? Thanks alot
"laravel/framework": "5.7.*",
"laravel/socialite": "^4.4",
The application is disabled - LinkedIn

Integrate Laravel Socialite with React Native Frontend using Passport

I have a Laravel server with socialite and passport. I installed the coderello plugin to have the grant_social type. When I authorize the social, I reply from laravel to the client with a JSON with the social auth token. How can I capture it from my react app so I can use to make API calls? And how should I login with social? Should I use manual redirect with a WebView or should I use the official social's SDKs?
I solved using a view as response that contains a script that calls window.ReactNativeWebView.postMessage and in my React app I use onMessage callback inside the WebView.

how can i get laravel tymon/jwt-auth refresh token?

i use laravel tymon/jwt-auth for jwt authentication. but when i authenticate, just get access token, not refresh token
in package.json
{
...
"require": {
"php": "^7.1.3",
"barryvdh/laravel-cors": "^0.11.3",
"fideloper/proxy": "^4.0",
"laravel/framework": "5.8.*",
"laravel/tinker": "^1.0",
"tymon/jwt-auth": "dev-develop"
}
...
}
i expect to get an refresh token to refresh the token after expiration, in the config/jwt.php i can set the expiration time for both access token and refresh token, but i can't get it. how to get the refresh token ?
First, go your project directory
Open the terminal or CMD inside your project directory and execute the below command
$ php artisan route:list
it will give you all the routes regarding your project including the auth routes, inside that route list you can see a route like this
POST | api/auth/refresh
you should send the POST request to the above route with by providing the expired access token inside the header or body as Bearer token. It will return the new token as the response.
Note: if the previous access token is not expired after calling the refresh token, endpoint previous token will be automatically expired.

Using OAuth2.0 Playground for testing

i wanted to test some API Requests from Proximity Beacon API. So i followed the steps from this site and put a test redirect url (https://developers.google.com/oauthplayground) into the OAuth-2.0-Client-ID. When i try to make an request from the playground i get following output:
{
"error": {
"status": "PERMISSION_DENIED",
"message": "Google Proximity Beacon API has not been used in project google.com:oauth-2-playground before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/proximitybeacon.googleapis.com/overview?project=google.com:oauth-2-playground then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.",
"code": 403,
"details": [
{
"#type": "type.googleapis.com/google.rpc.Help",
"links": [
{
"url": "https://console.developers.google.com/apis/api/proximitybeacon.googleapis.com/overview?project=google.com:oauth-2-playground",
"description": "Google developers console API activation"
}
]
}
]
}
}
obviously it is using the wrong project, but i only got to a step where i was able to pick my account but not my project. i checked everything twice and my only guess is that i cannot use this redirect_url.
So my question: Why is it trying to use the project google.com:oauth-2-playground instead of mine? And how can i change this?
The Proximity Beacon API was not enabled on the default credentials that the OAuth 2.0 Playground uses. I've just enabled that API and now this should work.
Alternatively you can setup the OAuth 2.0 Playground to use your own app's OAuth Credentials (Client ID and Client Secret) in the configuration menu of the playground.

How to do Google backend authentication of access token in Laravel 5.2?

I want to perform Google's backend verification in Laravel. Sorry about the confusion.
I want to get the access-token of the user validated by Google.
Does anyone know how to do it?
You can use cURL or Guzzle and manually authenticate with the Google API.
You should accept Alex Cobb's answer as it is correct. But since it is so short:
Someone else had a guzzle/socialite question similar, and has an acceptable excerpt for the code:
Making requests to Google API using Guzzle and Socialite in Laravel 5
And just in case you require Guzzle information:
http://www.pixelite.co.nz/article/guzzle-http-post-authentication-and-form-submission-symfony-20/
which shows how guzzle is the PHP solution in making curl call.
IMPORTANT NOTE:
why reinvent the wheel, laravel does this out of the box with socialite:
Laravel Socialite Introduction
Laravel Socialite provides an expressive, fluent interface to OAuth
authentication with Facebook, Twitter, Google, LinkedIn, GitHub and
Bitbucket. It handles almost all of the boilerplate social
authentication code you are dreading writing.
https://github.com/laravel/socialite

Resources