Forum Activity for @nate

nate
@nate
01/21/15 03:04:52PM
917 posts

Proxima Login fail


Proxima

Wait, I don't see the user array.
nate
@nate
01/21/15 03:02:23PM
917 posts

Proxima Login fail


Proxima

After looking at everything, I basically just need to change my checkout function to a proxima post or put and make the changes to the include file to be a proxima module. All my other lists can stay the same.

Thanks.
nate
@nate
01/21/15 12:40:10PM
917 posts

Proxima Login fail


Proxima

Does that mean I need to build the module inside the ACP?
nate
@nate
01/21/15 12:17:19PM
917 posts

Proxima Login fail


Proxima

I'll use proxima to create the user account and do my own log in.
updated by @nate: 01/21/15 12:18:48PM
nate
@nate
01/21/15 11:56:16AM
917 posts

Proxima Login fail


Proxima

So do I even need to use proxima? Have I wasted 2 days? A user account does me little good if I cant post as logged in.
updated by @nate: 01/21/15 12:11:33PM
nate
@nate
01/21/15 11:48:16AM
917 posts

Proxima Login fail


Proxima

N8: I did look at Proxima and meant to mention it in my question. Can I use it solely for authentication? I need to use my own module for building lists and transactions. Does it have docs?
updated by @n8flex: 02 Jan 2015 02:37:16PM - See more at: https://www.jamroom.net/the-jamroom-network/forum/jamroom-developers/20254/jamroom-new-user#last

Brian: Yep - you can use it for authentication. Here's a guide to the user service: - See more at: https://www.jamroom.net/the-jamroom-network/forum/jamroom-developers/20254/jamroom-new-user#last

I can see how this wasn't clear.
updated by @nate: 01/21/15 11:48:52AM
nate
@nate
01/21/15 11:42:59AM
917 posts

Proxima Login fail


Proxima

No. my module integrates Stripe to handle payments. I asked if this was allowed a few weeks ago.

function view_n8MSOne_checkout($_post, $_user, $_conf) {
	
	if (!jrUser_is_logged_in()) {
		$_re['msg'] = "user must be logged in";
		fdebug($_user);
		return n8MSOne_response($_re);
	}
	
	// validate post
	$_data = n8MSOne_validate($_post);	
	
	$file = APP_DIR . "/modules/n8MSOne/lib/Stripe.php";
	if (!is_file($file)) {
		jrCore_logger('CRI', "unable to load stripe library");
		$_re['msg'] = "Missing Stripe library";
		return n8MSOne_response($_re);
	}
	require_once $file;
	if ( strlen("{$_conf['n8MSOne_stripe_key']}") == 0) {
		jrCore_logger('CRI', "Stripe API key not set");
		$_re['msg'] = "System error";
		return n8MSOne_response($_re);
	}
	Stripe::setApiKey("{$_conf['n8MSOne_stripe_key']}");	
	
	// Create the charge on Stripe's servers - this will charge the user's card
	try {
		$charge = Stripe_Charge::create(array(
				"amount" 	=> $_data['total'],
				"card" 		=> $_data['token'],
				"description" 	=> $_data['email'],
				"currency" 	=> "usd"
			)
		);		
	} catch(Stripe_CardError $e) {
		$_re['msg'] = $e;		
		return n8MSOne_response($_re); 
	}

	// Create transaction record
	//$_data = n8MSOne_create_txn($_data, $charge);
		
	// Create puchases record for user
	//$_data = n8MSOne_create_purchases($_data);
	
	// Create sales record for seller
	//$_rs = n8MSOne_create_sales($_data);
	
	fdebug($_user);
	
	$_rs['type'] = "success";
	$_rs['msg'] = $_user['user_id'];
	
	// respond to app	
	return n8MSOne_response($_rs); 
}
nate
@nate
01/21/15 11:08:24AM
917 posts

Proxima Login fail


Proxima

I am posting the payment to my own module.
nate
@nate
01/21/15 11:07:12AM
917 posts

Proxima Login fail


Proxima

I just double checked the session ID. It is correct.
nate
@nate
01/21/15 10:53:29AM
917 posts

Proxima Login fail


Proxima

The client key.
  70