Skip to content

Product_Create

Jacob McConnell edited this page Jun 6, 2014 · 3 revisions

The ProductService class provides methods to create, retrieve, update and delete options.

##Method

###Create

Use to create an product.

####Arguments

  • TwoCheckoutConfig - Set your ApiUsername and ApiPassword.
  • ProductCreateServiceOptions Object containing create product attributes

####Returns

Returns a TwocheckoutResponse object.

####Example Usage:

var ServiceObject = new ProductService(); var ArgsObject = new ProductCreateServiceOptions();
 ArgsObject.name = "Test Product";
 ArgsObject.price = (decimal)2.00;

var result = ServiceObject.Create(ArgsObject);

####Example Response:

{TwoCheckout.TwoCheckoutResponse}
  response_code: "OK"
  response_message: "Product successfully created"
  product_id: "4831136155"

Clone this wiki locally