" dynamic="no"} Language Libraries | Developer Documentation | 2Checkout
Language

2Checkout Documentation

Link

The checkout function provides you with several methods to pass the sale and the buyer to 2Checkout.

Method

link

Description

Use to create a link to a sale to your custom checkout page.

Arguments

Returns

Returns a checkout link.

Example Usage:

var tco = new Twocheckout({
    sellerId: "1817037"
});

var params = {
    'mode': '2CO',
    'li_0_name': 'Test Product',
    'li_0_price': '0.01'
};

// Get a URL encoded payment link
var link = tco.checkout.link(params);

Example Response:

https://www.2checkout.com/checkout/purchase?mode=2CO&li_0_name=Test%20Product&li_0_price=0.01&sid=1817037