Payment problem

Maniaplanet public API, ManiaConnect system and the open source PHP SDK.

Moderator: NADEO

Post Reply
User avatar
steppie
Translator
Translator
Posts: 104
Joined: 25 Apr 2011, 21:55
Location: Denmark
Contact:

Payment problem

Post by steppie » 16 Jul 2012, 12:31

I've tried to get the payment to work, but when i call $p->create($t) I'm getting a Unauthorized exception

And next questions, how do I make a shot redirect? Do I have to use a maniacode to do that,
as you can't use header location?
Image
.Image

User avatar
magnetik
Nadeo
Nadeo
Posts: 1670
Joined: 01 Feb 2012, 19:13
Location: Bordeaux
Contact:

Re: Payment problem

Post by magnetik » 17 Jul 2012, 08:30

The best way to tell if the transaction issue comes from us : try ManiaLoto. Since it's using the same come as the one given, if it does not work it's an issue on our side.

Having a little more of your code may help :)
ManiaPlanet technical documentation portal (Dedicated, ManiaLink, ManiaScript, Titles...) -- contribute!

User avatar
steppie
Translator
Translator
Posts: 104
Joined: 25 Apr 2011, 21:55
Location: Denmark
Contact:

Re: Payment problem

Post by steppie » 17 Jul 2012, 13:42

Found the problem, my fault! :teub:

I've used this:

Code: Select all

$p = new \Maniaplanet\WebServices\Payments('API_USERNAME','API_PASSWORD');
instead of this:

Code: Select all

$p = new \Maniaplanet\WebServices\Payments(API_USERNAME,API_PASSWORD);
So now I'm getting a transactionid, but I still don't know how to redirect to a short url?
Image
.Image

The_Big_Boo
Posts: 1041
Joined: 15 Jun 2010, 15:46

Re: Payment problem

Post by The_Big_Boo » 17 Jul 2012, 14:40

To make a redirection with manialinks, just send an xml file with only a redirect tag like this:

Code: Select all

<?xml version="1.0" encoding="UTF-8" ?>
<redirect>shortag?transaction=xxx</redirect>
OS: Win 7 Pro x64
RAM: 2x4GB Corsair @ 1600MHz
CPU: Intel i5 760 @ 3.6GHz
Mobo: Asus P7P55D-E
GPU: NVidia GTX 760 2GB
HDD: WD Black 1TB
Sound: VIA VT1828S (onboard)
Peripherals: Razer DeathAdder - Razer DeathStalker - Logitech F310

User avatar
steppie
Translator
Translator
Posts: 104
Joined: 25 Apr 2011, 21:55
Location: Denmark
Contact:

Re: Payment problem

Post by steppie » 17 Jul 2012, 14:51

Thanks,

I did it another way, by making the "pay button" do the redirect.

But now it seems as the payment is taking planets before I confirm the payment?
Do the planets return if I refuses the payment?

[Edit]
On further test I can see that it's one planet thats taken from my account when the payment is requested,
Is that a "hidden" nadeo tax for using it?
Image
.Image

User avatar
gouxim
Nadeo
Nadeo
Posts: 1188
Joined: 14 Jun 2010, 17:20

Re: Payment problem

Post by gouxim » 01 Aug 2012, 16:13

In TMF it used to cost 1 or 2 Coppers to create a transaction, I suppose it's the same in Maniaplanet :?:
Please do not PM for support. Instead, create a thread so that everyone can contribute or benefit from the answer! 8-)

ethido
Posts: 9
Joined: 16 Aug 2011, 20:41

Re: Payment problem

Post by ethido » 30 Apr 2013, 20:29

gouxim wrote:In TMF it used to cost 1 or 2 Coppers to create a transaction, I suppose it's the same in Maniaplanet :?:
Are there any News about this? Just wanna know, if the 1 Planet Tax is also going to Nadeo, if the Player cancels the Transaction. Because this could mean, that a Player can repeatedly open such a Transactionslink till I'm poor ;).


Sorry for reopening after such a long time

User avatar
magnetik
Nadeo
Nadeo
Posts: 1670
Joined: 01 Feb 2012, 19:13
Location: Bordeaux
Contact:

Re: Payment problem

Post by magnetik » 02 May 2013, 08:30

No problem for reopening

I'm quite sure that there is no tax if the transaction is cancelled.

Have you tried making a transaction to check it?
ManiaPlanet technical documentation portal (Dedicated, ManiaLink, ManiaScript, Titles...) -- contribute!

ethido
Posts: 9
Joined: 16 Aug 2011, 20:41

Re: Payment problem

Post by ethido » 02 May 2013, 10:41

magnetik wrote: I'm quite sure that there is no tax if the transaction is cancelled.

Have you tried making a transaction to check it?
Yes, I have made a Dedi-Account to test it (entered the Dediaccount as "creatorLogin" and the "creatorPassword"). Then I made some Transactions on a Test-Manialink and always cancelled the Transaction.

Before the Transactions there were 87 Planets on the Account, after 17 Transactions (all cancelled) there are now only 70 Planets on the Account. This was yesterday at around 12:00, now nearly 24 Hours later, there are still only the 70 planets on the Serveraccount.
-> means that the 1 Planet Tax is also going to Nadeo if a Transaction is cancelled...

(Used a Serveraccount, because on my normal Login there is too many Planets income to observe this ;))

ethido
Posts: 9
Joined: 16 Aug 2011, 20:41

Re: Payment problem

Post by ethido » 10 May 2013, 13:55

Observed it now for more than a week. Created many Transactions and the 1 Planet-Tax is taken away from the $t->creatorlogin, no matter if its paid or cancelled...

Because of that I had to add a "Anti-TaxSpam" to my code which only allows a Login to create 10 unpaid Transactions a day, to prevent me getting poor by taxes...

By far not a great solution. So is this intended to take the Tax for an unpaid Transactions or will this change? ;)

Post Reply

Return to “Maniaplanet Web Services”

Who is online

Users browsing this forum: No registered users and 2 guests