Knowledge Base » Suppliers » Tech Support »

How do I upload a CSV file of my products?

You are able to upload a CSV file with your product information to our Version 2 database. Your CSV file must be in a specific format and all lines must be correct in order for the upload to be successful. If there is an error with the upload, our system will give you an error message stating which lines do not follow the proper format.

To upload a CSV file with your products, you will need to click on option 4 (set up products) from your account homepage. Next you will want to select the “Upload New Products” link located in the upper right corner of your computer screen. Simply browse your computer for the correct CSV file and select the upload button.

If you have any troubles with the upload, please use the following links to troubleshoot and set up your CSV file.

Here is a template:
https://www.2checkout.com/downloads/product_upload_template.csv

Here are instructions that explain the format:
https://www.2checkout.com/2co/admin/product_upload?instruct=1

What Authorize.net parameters does 2CO support?

Below you will find a listing of the supported Authorize.net-compatible parameters and what information each parameter should contain. This parameter set is used by third party carts and custom designed scripts. Please note that 2Checkout must know what is being sold in every sale. There are parameters available that allow for dynamic product creation. These will be discussed as well, and must be used if you are using this parameter set, but they are not Authorize.Net specific.

Multi-page Payment Routine:
https://www.2checkout.com/2co/buyer/purchase
Supports all payment methods. Supports tangible and intangible products/services.

Single Page Payment Routine:
https://www.2checkout.com/checkout/spurchase
Credit card-only payment routine only available for intangible products/services.

Required Parameters:
x_login - Your numerical 2checkout vendor account number.
x_amount - The total amount to be billed, without a currency symbol, and only two decimal places if used (8 characters, decimal, 2 characters: Example: 99999999.99)
x_invoice_num - A unique order id from your system. (64 characters max)

Product Identification Parameters:
Suppliers using this parameter set must pass in parameters to identify what is being sold during the purchase. These parameters will also benefit suppliers as when used correctly the product information will be displayed to customers on the purchase pages and will be listed on the suppliers 2Checkout.com sale detail page.

id_type - Due to changes in with the Product Identification parameters this parameter should be passed in once during the purchase and will need to have its value set to 1.
c_prod - The ID of the product that is being purchased. The quantity of product being purchased can passed with this parameter by placing a comma after the ID and then the quantity in numeric format.
c_name - The value of this parameter should contain the name of the product to be created. (128 characters max)
c_description - The value of this parameter should contain a short description of the product to be sold. (255 characters max)
c_price - The price of your product. Please note that in order to prevent a discrepancy between the total parameter and the sum of the product identification c_price parameters which may confuse the customer, the product price will not be displayed on the purchase page. (8 characters, decimal, 2 characters: Example: 99999999.99)

You can use these identification parameters to pass in multiple products as well. To do so you will need to append a digit to each parameter. For example, c_prod_1, c_name_1, c_description_1, c_price_1 will describe the first product, then to describe the second product you would use a 2 so the parameters will read c_prod_2, c_name_2 and so on.

Additional Parameters:
demo - Y to enable demo mode. Do not pass this in for live sales. Can also be controlled within the account.
lang - “sp” for Spanish purchase routine pages, defaults to English if this is absent, but “en” may be used for English as
well.
merchant_order_id - Specify your order number with this parameter. It will also be included in the confirmation emails to yourself and the customer. (50 characters max)
pay_method - CC for Credit Card, CK for check, PPI for PayPal, PPL for PayPal Pay Later, or FXS for FXSource. This will set the default selection on the payment method step during the checkout process.
skip_landing - If set to 1 it will skip the order review page of the purchase routine.
x_Receipt_Link_URL - Used to specify an approved URL on-the-fly, but is limited to the same domain that is used for your 2Checkout account, otherwise it will fail. This parameter will over-ride any URL set on the Look and Feel page. (no limit)

To populate the billing information page you may pass in:
x_First_Name - buyers first name (64 characters max)
x_Last_Name - buyers last name (64 characters max)
x_Phone - buyers phone number (16 characters max)
x_Email - buyers email address (64 characters max)
x_Address - buyers address (64 characters max)
x_City - buyers city (64 characters max)
x_State - buyers state (64 characters max)
x_Zip - buyers zip code (16 characters max)
x_Country - buyers country (64 characters max)

To populate the shipping information page you may pass in:
x_Ship_To_First_Name
x_Ship_To_Last_Name
x_Ship_To_Address
x_Ship_To_City
x_Ship_To_Country
x_Ship_To_State
x_Ship_To_Zip

Please note that since this parameter set is for third party shopping carts, we do not collect shipping information for these types of orders. This is because your cart is responsible for calculating the shipping and it is passed in as part of the x_amount parameter. We will present the shipping information page if any of the shipping parameters are passed in, but this does not mean we will apply shipping charges to the order. If the shipping information is passed in, we will also populate the billing information using that information unless any of the above parameters are passed in by your cart to populate the billing information page.

It is also important to note that when using the Authorize.Net set of parameters, 2CO only requires the three listed under the required section. We will therefore not passback strictly Authorize.Net style parameters for everything unless they are passed in to us. This is not often a problem as most carts do this anyways. For example, x_First_Name and x_Last_Name will prepopulate the billing name, but 2CO uses cardholder_name for this. cardhold_name will then be returned unless x_First_Name and x_Last_Name are passed into 2Checkout.

Custom Parameters:
You may pass in any additional parameters that you may need and they will be returned to you at the end of the sale. The only restrictions on custom parameters are that they can not share the name of ANY parameter that our system uses, even from the other sets. Please note that you WILL need a return script set up on the Look and Feel page to receive any of these parameters back as they are not included in the confirmation emails.

Return Parameters:
You can receive back all of the parameters that were passed in as well as the following parameters:
x_2checked - Y if card was successfully processed, K if pending.
x_MD5_Hash - The MD5 hash that can be used to verify that the sale came from a 2CO server.
x_trans_id - the 2CO order number for the order.

Using this parameter set, we are not receiving any product information. As you can see, you are only passing in a total amount to us. Usually, the cart will have some means of using the x_invoice_num to determine what was purchased after the sale. A return URL will need to be set up on the Look and Feel page for the cart to correctly determine this.

Consult the documentation that came with your cart or contact the cart manufacturer for assistance with setting this up or to determine what URL you should enter on the Look and Feel page for your cart to receive the product information.

Recurring billing can not be done with this parameter set. You must use the Plug-N-Play parameter set and have the products defined within the 2CO database for recurring billing.

Important: You can not mix the three parameter sets. This will cause problems during payment or may prevent the payment pages from working at all.

Important Note: When you are testing parameters, please be certain to clear the cookies in your browser between tests to ensure the changes you have made are applied. For more information on clearing the cookies please click here.

Related Article: Country Codes

What are 2Checkout.com’s own parameters?

2CO has our own proprietary set of parameters that you can use if your cart supports them.

Multi-page Payment Routine:
https://www.2checkout.com/2co/buyer/purchase
Supports all payment methods. Supports tangible and intangible products/services.

Single Page Payment Routine:
https://www.2checkout.com/checkout/spurchase
Only supports credit card payments and intangible products/services.

Required Parameters:
sid - Your 2Checkout vendor account number.
total - The total amount to be billed, in decimal form, without a currency symbol. (8 characters, decimal, 2 characters: Example: 99999999.99)
cart_order_id - A unique order id from your program. (128 characters max)

Product Identification Parameters:
Suppliers using this parameter set must pass in parameters to identify what is being sold during the purchase. These parameters will also benefit suppliers as when used correctly the product information will be displayed to customers on the purchase pages and will be listed on the suppliers 2Checkout.com sale detail page.

id_type - Due to changes in with the Product Identification parameters this parameter should be passed in once during the purchase and will need to have its value set to 1.
c_prod - The ID of the product that is being purchased. The quantity of product being purchased can passed with this parameter by placing a comma after the ID and then the quantity in numeric format.
c_name - The value of this parameter should contain the name of the product to be created. (128 characters max)
c_description - The value of this parameter should contain a short description of the product to be sold. (255 characters max)
c_price - The price of your product. Please note that in order to prevent a discrepancy between the total parameter and the sum of the product identification c_price parameters which may confuse the customer, the product price will not be displayed on the purchase page. (8 characters, decimal, 2 characters: Example: 99999999.99)

You can use these identification parameters to pass in multiple products as well. To do so you will need to append a digit to each parameter. For example, c_prod_1, c_name_1, c_description_1, c_price_1 will describe the first product, then to describe the second product you would use a 2 so the parameters will read c_prod_2, c_name_2 and so on.

Additional Parameters:
demo - Y to enable demo mode. Do not pass for live sales. Can also be controlled within the account.
lang - “sp” for Spanish purchase routine pages, defaults to English if this is absent, but “en” may be used for English as well.
merchant_order_id - Specify your order number with this parameter. It will also be included in the confirmation emails to yourself and the customer. (50 characters max)
pay_method - CC for Credit Card, CK for check, PPI for PayPal, PPL for PayPal Pay Later, or FXS for FXSource. This will set the default selection on the payment method step during the checkout process.
skip_landing - If set to 1 it will skip the order review page of the purchase routine.
x_Receipt_Link_URL - Used to specify an approved URL on-the-fly, but is limited to the same domain that is used for your 2Checkout account, otherwise it will fail. This parameter will over-ride any URL set on the Look and Feel page. (no limit)

To pre populate the billing information page you may pass in:
card_holder_name - Card holder’s name (128 characters max)

The card holder’s name can also be populated using the first_name, middle_initial, and last_name parameters. IMPORTANT: If you use these three parameters, the data will be combined into and returned as card_holder_name to your Approved URL script.

street_address - Card holder’s street address(64 characters max)
street_address2 - The second line for the street address, typically suburb or apartment number information (64 characters max)
city - Card holder’s city (64 characters max)
state - Card holder’s state (64 characters max)
zip - Card holder’s zip (16 characters max)
country - Card holder’s country (64 characters max)
email - Card holder’s email (64 characters max)
phone - Card holder’s phone (16 characters max)
phone_extension - Card holder’s phone extension (9 characters max)

To pre populate the shipping information page you may pass in:
ship_name
ship_street_address
ship_street_address2
ship_city
ship_state
ship_zip
ship_country

Please note that shipping information will only be collected for items that are defined as tangible in our system. Shipping is also only charged for tangible items. We will ask for shipping information if you pass in any of the shipping parameters, regardless of whether the item is tangible or not. This does not mean we will apply shipping charges to the sale, but their information will be collected.

The billing information page will also be populated with the information from the shipping page if the shipping information is collected on that sale and the billing information is not passed in.

Custom Parameters:
You may pass in any additional parameters that you may need and they will be returned to you at the end of the sale. The only restrictions on custom parameters are that they can not share the name of ANY parameter that our system uses, even from the other sets. Please note that you WILL need a return script set up on the Look and Feel page to receive any of these parameters back as they are not included in the confirmation emails.

You can receive back all of the parameters that were passed in as well as the following parameters:
order_number - 2Checkout.com order number
cart_order_id - Your cart ID number passed in.
credit_card_processed - Y if successful (Approved), K if waiting for approval (Pending)
key - the MD5 hash used to verify that the sale came from one of our servers

Consult the documentation that came with your cart or contact the cart manufacturer for assistance with setting this up or to determine what URL you should enter on the Look and Feel page for your cart to receive the product information.

Recurring billing can not be done with this parameter set. You must use the Plug-N-Play parameter set and have the products defined within the 2CO database for recurring billing.

Important: You can not mix the three parameter sets. This will cause problems during payment or may prevent the payment pages from working at all.

Important Note: When you are testing parameters, please be certain to clear the cookies in your browser between tests to ensure the changes you have made are applied. For more information on clearing the cookies please click here.

Related Article: Country Codes

What are the New Cart Purchase Parameters?

Announcement

The new cart purchase parameter descriptions have been integrated into the parameter set articles they are required for. Please review the “Product Identification parameters” section of the 3rd party cart parameter article or the Authorize.net parameter article to find information on these parameters. The information below is provided for historical reference only.


It has become necessary for 2CO to know the specific product that is being sold at the time of sale and for that product’s description to be stored in our database for reference. This change is required both by 2CO and by our banking partners to better mitigate risk and to monitor items being sold. Because of this requirement, we are asking cart makers and/or users to make changes to their cart or programs so that additional information about the items being sold is passed to 2CO.It is very important to note that:
  1. All previous parameters remain supported and should continue to be passed in (2CO, Authorize.net),
  2. The parameter total (or the authorize.net parameter : x_amount) passed in for the order will continue to be the amount billed for the sale,
  3. The paramaters cart_order_id and sid (or the authorize.net parameters: x_invoice_num and x_login) are still manditory with this parameter set.

REQUIRED PARAMETERS
These parameters are required to identify cart products being purchased and should be supplied ASAP.

For some clients it may make sense to create 1 or multiple generic products in the 2CO db, like “Premium Hosting”, “Super Saver Hosting” and pass in a total for the sale as generated on their site. If this option works for you please make the product name reasonably descriptive, (i.e. “website design services” would be a good description, “web services” a poor one for the same item ).

  • c_prod or c_prod_[:digit] : This parameter will contain either the assigned_product_id given to the product upon creation in the 2CO system or a vendor specified id. It may, optionally, also contain the id followed by a ‘,’ (ASCII comma) followed by an integer which will represent the quantity. This parameter should not be autogenerated with each individual sale but should be tied to a specific product. The c_prod value should match whatever external vendor id is recorded in the 2CO system. The external vendor id may be a cart assigned product id or the vendors own internal product id as long as the value matches the value stored in the 2Co system. Examples of valid values:
    • 1
    • my_product_17
    • product_5,3
  • id_type This parameter will contain an integer value representing the type
    or classification of the ids used in the c_prod parameter(s). This value will
    apply universally per transaction. That is to say c_prod parameters must contain
    only assigned_product_id values or only vendor_product_id values. Current
    valid values for this parameter are defined as follows.
    • 1 is defined as vendor_product_id
    • 2 is defined as assigned_product_id
    • 3 - 0 are reserved for future use.

OPTIONAL PARAMETERS
These parameters are intended for carts that retain no product database or as a transition method of populating the 2CO database. Although it is desirable to receive as many parameters as possible with the purchase the option of creating products on the fly should only be used when no other options exist.

  • sh_cost (optional) : This parameter will contain shipping and handling cost, if any. The sh_cost parameter is completely optional. This parameter has the same format rules as the parameter containing the total (total or x_amount) that you are currently using. This value received is assumed to be in the selected currency of your 2CO account.
    Examples of valid values: 0.50, 5.00, 10
  • c_name or c_name_[:digit] : This parameter is required for product information to be displayed at checkout. The value of this parameter should contain the name of the product to be created. It is limited to 128 characters including spaces and punctuation. If the value is too long it will be cut off at 128 characters.
  • c_description or c_description_[:digit] : This parameter is required for product information to be displayed at checkout. The value of this parameter should contain a short description of the product to be sold. It is limited to 255 characters including spaces and punctuation. If the value is too long this value will be stored as the long description instead. The long description will not show on the checkout pages but it will be saved in the 2Co product database.
  • c_price or c_price_[:digit] : This parameter is required for product information to be displayed at checkout. This value should reflect the price of the product in your 2CO account selected currency. This parameter has the follow format restrictions
    • Numbers and decimal point only.
    • Max value: 999999.99
  • c_tangible or c_tangible_[:digit] (optional) : This parameter is optional. If you do not provide a value for it a default value of Y will be used. This field indicates if the product is a physical product or an e-good/service.
    This parameter has the following format restrictions: Valid values: y Y n N

NEW PARAMETERS IN PRACTICE
Below you will find an example form that shows how these new parameters might be implemented:

<form action="https://www.2checkout.com/2co/buyer/purchase" method="post">

	<input type="hidden" name="id_type" value="1">
	<input type="hidden" name="c_prod_1" value="QAWSZX0678,3">
	<input type="hidden" name="c_name_1" value="Sample 	Product">
	<input type="hidden" name="c_description_1" value="Sample Product Description">
	<input type="hidden" name="c_price_1" value="5.00">
	<input type="hidden" name="c_tangible_1" value="N">

	<input type="hidden" name="c_prod_2" value="CABLE0029,1">
	<input type="hidden" name="c_name_2" value="A Second Sample Product">
	<input type="hidden" name="c_description_2" value="This Products Description">
	<input type="hidden" name="c_price_2" value="10.00">
	<input type="hidden" name="c_tangible_2" value="N">

	<input type="hidden" name="sid" value="XXXXXX">
	<input type="hidden" name="cart_order_id" value="050304-102658-3874">
	<input type="hidden" name="total" value="25.00">

	<input type="submit">
</form>

Please note that you will need to replace the sample values with your own.

Can you give me more information about the MD5 Hash?

This parameter is used to verify the passbacks for you. Depending on what parameter set you are using, this will either appear as ‘key’ or ‘x_MD5_Hash‘. The MD5 hash is also provided to help you verify the authenticity of INS posts. On INS posts the hash is returned in the md5_hash parameter.

One of the Md5 hash components involves a secret word that can be set by you. To set it, follow these directions:

Setting Your Secret Word:

  1. Login to your account.
  2. Click on “Look and Feel” found on your account homepage.
  3. Enter your secret word into the data field labeled, “Your Secret Word (16 Character Limit)”. As labeled, the only limit is that it must be 16 characters or less.
  4. Click “Save Changes” when you are finished.

Please read the related article below for more information about the MD5 Specifications.
How do I use the MD5 Hash?

Where do I set up the Secret Word?

When you log in to your 2co account, on the main page of your Admin Area, in the ‘Helpful Links’ box, there is a link to “Look and Feel”. If you go to that section of your Admin area, at the bottom of that screen, you can set up your Your Secret Word ( 16 Character Limit ). Then click SAVE CHANGES.

The secret word is used by those wishing to check the MD5 hash passback, with a routine on their site. It is also needed by those using a program like the membership or download client. The secret word is also used to calculate the MD5 hash which is sent to verify the authenticity of INS posts.

The secret word should be a single or compound word or group of letters and numbers with no spaces. Examples: Monkey1mouse, 4smal3phone, gooblyWbubze.

How do I use the MD5 Hash?

The MD5 hash is provided to help you verify the authenticity of a sale. This is especially useful for vendors that sell downloadable products, or e-goods, as it can be used to verify whether sale actually came from 2Checkout and was a legitimate live sale. We intentionally break the hash code for demo orders so that you can compare the hash we provide with what it should be to determine whether or not to provide the customer with your goods or not.

To calculate the MD5 hash, you need to make a string that contains the information described below and pass it in as the value to your scripting languages MD5 function. Below is an example:

md5 ( secret word + vendor number + order number + total )

The secret word is set by yourself on the Site Managment page. The vendor number is your numerical vendor/seller ID number. The order number is the order number for the sale. The total is the numerical value for the total amount of the sale.

Demonstration:

Secret Word => tango
Vendor Number => 123456
Order Number => 9999999
Total => 5.99

md5hash = md5( tango12345699999995.99 )

It is important to note that the MD5 hash must also be converted to upper case letters for a clean comparison. How this is done depends on the scripting language that you use. Below are some examples of how to compute the MD5 hash using PHP. This should illustrate how this process works.

The following code would be applicable to orders placed using our Plug and Play cart and our proprietary third party set of parameters.

$string_to_hash = “tango123456″ . $_POST[”order_number”]
.
$_POST[”total”];
$check_key = strtoupper(md5($string_to_hash));

echo (”Returned MD5 Hash : ” . $_POST[”key”]
. “<BR>”);
echo (”Should be : ” . $check_key . “<BR>”);

if($check_key == $_POST[”key”]){
// At this point the expected key and the returned key match, so the customer should be given access to the download
// This is where you would want to put the code or page for the download
echo (”<center>They match!</center>”); }
else {
// At this point the keys do not match, so either the attempt was fraudulentor a demo order
// This is where you would put the code or page for an unsuccessful attempt
echo (”<center>They do NOT match! Was this a demo order?</center>”);}

The following code would then be applicable to orders placed using the Authorize.net
parameter set.

$string_to_hash = “tango123456″ . $_POST[”x_trans_id”]
.
$_POST[”x_amount”];
$check_key = strtoupper(md5($string_to_hash));

echo (”Returned MD5 Hash : ” . $_POST[”x_MD5_Hash”]
. “<BR>”);
echo (”Should be : ” . $check_key . “<BR>”);

if($check_key == $_POST[”x_MD5_Hash”]){
// At this point the expected key and the returned key match, so the customer
should be given access to the download
// This is where you would want to put the code or page for the download
echo (”<center>They match!</center>”); }
else {
// At this point the keys do not match, so either the attempt was fraudulent
or a demo order
// This is where you would put the code or page for an unsuccessful attempt echo (”<center>They do NOT match! Was this a demo order?</center>”);}

The MD5 hash is also provided to help you verify the authenticity of INS posts. The MD5 hash that is sent with INS posts is a hash of sale_id + vendor_id + invoice_id + secret word in the md5_hash parameter.


Demonstration:

sale_id => 9999999999
vendor_id => 123456
invoice_id => 1111111111
Secret Word => tango
md5hash = md5( 99999999991234561111111111tango )

The following code would be applicable to orders placed using our Plug and Play cart and our proprietary third party set of parameters.

$string_to_hash = $_POST[“sale_id”] . “123456” . $_POST[“invoice_id”] . “tango”;
$check_key = strtoupper(md5($string_to_hash));
echo (“Returned MD5 Hash : ” . $_POST[“md5_hash”]
. “
”);
echo (“Should be : ” . $check_key . “
”);
if($check_key == strtoupper($_POST[“md5_hash”])){
// If the expected key and the returned key match the authenticity of the message has been validated.
echo (”They match!”); }
else {
// At this point the keys do not match.
// This is where you would put the code for an unsuccessful attempt.
echo (“They do NOT match!”);}

Please note that help with implementing the MD5 hash into your return script is beyond the realm of 2Checkout.coms support. This document is provided merely as a reference document to help point you in the right direction. How the MD5 hash is computed is Dependant upon the scripting language that you use. Implementation of any MD5 hash checking is solely on your end or your server. 2Checkout.com can not provide you with support in implementing this or troubleshooting your implementation. We provide you with the hashes as a convenience to help you protect your digital goods.

The following links may be of interest to you if you are looking for more information on the MD5 algorithm and its use.

http://userpages.umbc.edu/~mabzug1/cs/md5/md5.html
http://en.wikipedia.org/wiki/MD5
http://msdn.microsoft.com/library/en-us/cpref/html/frlrfSystemSecurityPolicyHashClassMD5Topic.asp

We have also intentionally designed the MD5 hash not to work for demo sales as was explained earlier. If the sale is in demo mode, the order number used to create the hash will be forced to a one, which will cause the hashes to be different when you compare them. If you wish to test the hashes, you’ll have to place a live test order using a real credit card number.

The MD5 hash isn’t working. Why?

Was the sale a demo sale?

The MD5 hash most commonly fails because the account is in demo mode. If the sale was in demo mode, then the order number used to compute the hash on the 2CO side is forced to ‘1′. This will cause the hash to fail since the strings will not match up. This is done intentionally to protect those who sell digital goods from fraudulent purchases.

If the hash fails and was not a demo sale, then this most likely means that someone tried to access your digital goods without paying for them. That is exactly what the MD5 hash is designed to alert you of.

If the hash is failing on a INS post please read the related article below for more information about the MD5 specifications.
How do I use the MD5 Hash?

How do I test the MD5 hash?

Because MD5 is designed to fail in demo mode for security reasons, the only way to test the MD5 hash is to perform a live test order using a real credit card. Note that if you cancel the test order from the admin panel immediately afterward, no transaction fees will apply to the sale.

Page 19 of 19« First...«1516171819

Recent Posts from the Community:

Voucher possible?

posted by: isay

Pay from 2co

posted by: starcom

Vendor Issue

posted by: manz135
More from the community »

Now a faster, easier way to get paid – the 2CO reloadable MasterCard®.

Sign up today and receive a $10 credit on your card.


Click here to learn more.

Spotlight Supplier

Spotlight Supplier

Chocolate Shoppe

Spotlight Product

Spotlight Product

Canadian Mini Muks


Popular Tags