Request Parameters:


This method is used to set checkout attribute to cart

Note: In checkout attribute for checkbox control type you need to pass checkbox id. For select multiple value in checkbox, pass comma separated checkbox value id.

URL: ../Api/Client/SetCheckOutAttribute


Header:

Content-Type:application/json


Required Parameters :  


Case-1. Exception parameters :
Parameter:
{

           "ApiSecretKey":"i99b98d117m116a112o98k115c111",

         "CustomerGUID":"496DBB2A-F9EB-4522-A804-B108693B69CE",

           "StoreId": "",

        "CurrencyId": "",

        "LanguageId": "",

        "CheckoutAttributeResponse":

          [{

                  "AttributeId": "1", "AttributeValue": "2"

        }]

}
Response :
{

    "Status": 0,

    "Message": "Request cannot be empty",

    "Data": null,

    "ValidationMessage": [],

    "ErrorMessage": null

}


Case-2. Incorrect Parameters :

Parameter:
{

    "ApiSecretKey":"i99b98d117m116a112o98k115c111",

         "CustomerGUID":"496DBB2A-F9EB-4522-A804-B108693B69CE",

    "StoreId": "1",

        "CurrencyId": "1",

        "LanguageId": "1",

        "CheckoutAttributeResponse":

          [{

          "AttributeId": "52", "AttributeValue": "1"

        }]

}
Response :

{

    "Status": 0,

    "Message": null,

    "Data": null,

    "ValidationMessage": [],

    "ErrorMessage": "Object reference not set to an instance of an object."

}


Case-3. Success Response :

Parameter:
{

    "ApiSecretKey": "i99b98d117m116a112o98k115c111",

    "CustomerGUID": "496DBB2A-F9EB-4522-A804-B108693B69CE",

    "StoreId": "1",

    "CurrencyId": "1",

    "LanguageId": "1",

    "CheckoutAttributeResponse": [

        {

            "AttributeId": "1",

            "AttributeValue": "2"

        },

        {

            "AttributeId": "3",

            "AttributeValue": "1-February-2019"

        }

    ]

}

Response :

{

    "Status": 1,

    "Message": "Success.",

    "Data": {

  "CheckoutAttributeInfo": "Gift wrapping: Yes [+$10.00]<br />Donate to save child: Yes [+$10.00]",

        "CustomerGuid": "496dbb2a-f9eb-4522-a804-b108693b69ce",

        "Message": "Checkout attribute set successfully "

    },

    "ValidationMessage": [],

    "ErrorMessage": null

}