Language

2Checkout Documentation

Retrieve

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

Methods

retrieve

Use to retrieve an Option object.

Arguments

  • TwoCheckoutConfig - Set your ApiUsername and ApiPassword.
  • OptionRetrieveServiceOptions - Object composed of detail option attributes.

Returns

Returns a Option object.

Example Usage:

var ServiceObject = new OptionService();
var ArgsObject = new OptionRetrieveServiceOptions();
ArgsObject.option_id = option_id;

var result = ServiceObject.Retrieve(ArgsObject);

Example Response:

{TwoCheckout.Option}
  option_id: 4831124727
  option_name: "test"
  option_values: ...
    {TwoCheckout.OptionValues}
      option_value_id: 4831124730
      option_value_name: "test"
      option_value_surcharge: 1.00