Skip to main content

Create a Customer Session

Creates a customer session resource.


Endpoint

POST /customer_sessions

Sample code

const client = require('payrex-node')('insert your PayRex Secret API key.');

const customerSession = await client.customerSessions.create({
customer_id: '<insert customer id here>',
});

Parameters

customer_id REQUIRED

The ID of a customer resource. To learn more about the customer resource, you can refer here.

Returns

Returns a Customer Session resource.