I am using stripe component in my application,when I tested with sk_test_1XXXXXX all payments were success,now I changed that key to another sk_test_2XXX,when iam trying to pay through this,getting an error "No such custome -cus_xxxxxxxxxxx".How to resolve this.
You created that customer with your 1st test key. These customers will be invisible (as well as any cards, subscriptions, etc) to your second test key.
Once you changed / moved key you'll need to recreate these test customers, they are not shared between test keys and accounts.
Your customer does not exist. Try login into the stripe dashboard and seeing if that customer exists.
Related
I have an app that uses stripe payments and I am trying to allow users' cards to be charged. I have successfully changed the pk_test to pk_live but I am having issues changing sk_test to sk_live. I had paid someone to install stripe for me, and the only reference I can see to sk is inside of node.js as
const stripe = require('stripe')(functionConfig().stripesecretkeys.key);
This leads me to believe that the individual used terminal to reference the sk_test. My question is, how can I change this to be live instead of test.
I see this on firebase Doc,
firebase functions:config:set stripe.secret=<YOUR STRIPE LIVE SECRET KEY>
EDIT:
I have managed to add the secret key in through terminal, but when I create a new customer they are still being created under test mode on stripe? am I missing something?
Can someone help me to understand how make Payment Form works for merchants?
I am working on ECommerce site where merchants can sell their products. To use Square as payment provider I used OAuth to retrieve access token (which works fine).
To take payment I use Payment Form (to get card nonce). On Payment Form init I need to send ApplicationID & LocationId. I'am able to get last one but not the first one param.
If I try to use my own ApplicationID I get the error on Transactions/Charge
{
"errors":[{
"category":"INVALID_REQUEST_ERROR",
"code":"NOT_FOUND",
"detail":"Card nonce not found in this `sandbox` application environment. Please ensure an application ID belonging to the same environment is used for the SqPaymentForm."
}]
}
This error happens when you use a combination of sandbox application Ids and production application Ids. I'm guessing that you are using your correct application id, and attempting to charge with your sandbox access token.
If you want to take a sandbox payment with the payment form, use your sandbox application id, it should look like sandbox-sq0idp-XXXXXXXXXXXXXXXXXXX
Each merchant must use their own credentials to load locations. You must send the merchant locationId selected and their access_token to do the charge in its account.
Carlos
I'm trying to setup the payout process for the merchants on my site, but for some reason when I use Stripe Test bank details I get with the error of "Known test bank accounts cannot be used in live mode". I'm using the development client ID for testing obviously, so not sure why am I end up with this error. :( Any ideas would be very welcome! Thanks.
The activation form expects real information about a real business. This means that even if you're testing, you might want to create a real account with real details and that's what Stripe asks for here.
Since you're only testing the OAuth flow and don't want to activate your account you should ignore the form entirely. When testing with your Development client id ca_XXXXX there should be a link at the top of the form called "Skip this account form". This links lets you bypass the activation form (which would be required in production) and finish the connection with the platform.
I'm trying to use the Google Calendar API in one of my projects. To do so, I need to set up OAuth access in the Google API console.
But when creating the consent-form (which is required to use OAuth), I get a meaningless error message:
The translation is as follows:
A problem occured. Please check your data and try again . If you have
not given any details, the problem may solve itself . In this case, we
recommend that you wait and try again later.
I have set the E-Mail address and project name. The optional fields were left blank.
So far I have not been able to solve the problem. I tried to wait for hours/days. I tried three different browsers. I also tried to contact Google support. All without success.
After days of trying, this is the solution:
Create another Google account
Using your old account, add the new account as an owner to your Google API project in the console
Log in with your new user account and accept the invitation
Create the OAuth consent form with the new user account
I have no idea WHY this worked, but it did.
I am trying to automate the entire process of creating a google apps account through my company's reseller account with google, without any human having to manually enable anything.
Here's a quick scenario of what I am doing.
Create Customer (Domain) with Reseller API
Create Subscription with Reseller API
Create Admin Account for the Sold Domain
I am having trouble automating step 3.
There are 2 different APIs that can accomplish this tast, Provisioning (depricated) and Directory.
I have already successfully created user accounts with the Directory API, but this step requires you to enable API access for that domain, and that can only be done manually by a human - So thats a break in automation flow, and wont work for what I am trying to accomplish.
I was instructed by google tech support to use the Provisioning API, wich is deprecated, because it supposedly allows you to create an admin user without the need to enable the API access manually per domain. When I attempt to do this, I face this error:
Uncaught exception 'Zend_Gdata_App_HttpException' with message 'Expected response code 200, got 403 <HTML> <HEAD> <TITLE>You are not authorized to perform operations on the domain mydomain.com</TITLE>
Here's the code im attempting to run:
// .....
$customerid = "somedomain.com";
$client = Zend_Gdata_ClientLogin::getHttpClient("mylogin#foo.com", "mypassword",Zend_Gdata_Gapps::AUTH_SERVICE_NAME);
$gdata = new Zend_Gdata_Gapps($client, $customerid);
$gdata->createUser('Admin', 'Firstname', 'Lastname', 'somerandompassword', TRUE);
//......
When I consulted google tech support, they told me I needed to enable the provisioning api following the same instruction I posted earlier (enable api access per domain). I have done this on both my reseller domain, and the customer domain Im trying to provision on (just to test, becasue the entire point is to be able to make an admin account WITHOUT enabling it on the customer domain.) - But it still returns this error.
Here's my settings -- as you can see, its enabled.
In google's docs, under "Enabling the Provisioning API", it has some instructions, but they appear to be out of date and dont really reflect sections available in the current google apps admin panel.
Im at a loss. Am I missing something obvious, or is it just not possible to do at this time?
Just for reference, I have found a few other people asking a similar question, but with less detail:
Google Reseller Customer Admin User Creation Admin SDK How
How to create the domain administrator of a Google Apps domain purchased via the reseller API
EDIT: Added image showing settings, and code sample.
try to delete "TRUE" parameter in createUser , it's works for me.
$customerid = "sampledomain.com";
$client = Zend_Gdata_ClientLogin::getHttpClient($email, $password, Zend_Gdata_Gapps::AUTH_SERVICE_NAME);
$gdata = new Zend_Gdata_Gapps($client, $customerid);
var_dump($gdata->createUser('trial', 'Firstname', 'Lastname', 'somerandompassword'));
in Google app console
domain settings ->user settings
check the box "enable API access"
in Google app console --> advanced tools --> Manage third party OAuth Client access
Add the scope :
https://apps-apis.google.com/a/feeds/user