Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Added GiftCertificate parameter

...

ParameterNotes
arbitraryunitcostallows you to set a cost for the item within a range of valid prices
ReferralCodeMust match an actual referral program unless UltraCart support has turned on a flag to allow any arbitrary code to be passed
OVERRIDECATALOGURLURL That the customer is sent to after they have completed the order. This overrides the default behavior of sending them back to whatever the referrer header of the original request indicated.
OVERRIDECONTINUESHOPPINGURLURL that the customer is sent to after they click continue shopping. This overrides the default behavior of sending them back to whatever the referrer header of the original request indicated.
ThemeCodeSets the theme code of the branding to be used during the checkout. This should be used by merchants that have multiple branding themes.
Not Applicable for newer merchants on StoreFronts. 
RtgCodeSets the specific rotating transaction gateway that should be used to process this order.
CurrencyCodeIf you have multi-currency enabled, this parameter sets the specific currency code for the checkout.
COUPONCode of a coupon to add to the cart
ClearCouponIf this parameter is "true" then all coupons on the cart are removed.
GiftCertificateGift certificate code to apply to the cart.
AFFIDAppends Affiliate ID to a buy link. (Note you can also add the also append the Sub-ID)
SUBIDAppends a sub-ID to the affiliate which allows for tracking where the link is used (more details here regarding using Sub-ID's with affiliate links)
PREFERREDDCCODECODE (Where CODE= the Distribution Center Code - This parameter is used with accounts that have multiple distribution centers in order to force an order to use a specific distribution center to the order.
SendToUrl

Immediately send the browser to another url after adding the information to the cart.  This URL must be one of the permitted ones based upon your UltraCart account merchant profile, catalogs, StoreFronts or SSL certificates.

Info
titleSendToUrl - whitelist requirement

You must contact support to have them whitelist the URL to which the customer will be sent. Each domain that is used as the target must be white listed by our support staff in order to prevent abuse as an open relay.


ImmediateContinueShoppingImmediately send the browser back to the page that clicked the add to cart button.
ImmediateCheckoutIf specified the customer is forced in to an immediate checkout.
LanguageIsoCodeIf you are using a multi-lingual StoreFront, you can pass the three letter ISO language code to trigger a specific language. By default StoreFronts will look at the browsers Accept-Language header to determine which language the customer desires so we recommend only passing this if you dealing with a checkout only scenario and and a external single language website.
passThru

Any parameter that starts with passThru will be carried through to the next page. 

Info
titlepassThru Size Limit
The limit is 10kb of passThru parameters.

Examples:

  • &passThruGreen=Red
  • &passThru_showWarning=true
  • &passThruVip=1


prop_<name>=<value>

props_json=<json string>

Cart Properties are new features of UltraCart shopping carts and orders.  They supplement custom fields by allowing for a nearly unlimited number of custom properties for a cart.  They are designed for and accessible only through the UltraCart Rest API.

There are two methods for setting cart properties: simple and json.

Simple

add query parameters using the format prop_<name>=value.

Examples:

?merchantId=DEMO&prop_color=red&prop_vip=true&prop_bilbo=baggins

JSON

For a json parameter, create an array of CartProperty objects ('name' and 'value'), then url encode it and pass it as the props_json parameter.

Example:

Cart properties of A=Anteater, B=Boar, and C=Cat.

JSON (notice this is an array): [{name:"A", value:"Anteater"},{name:"B", value:"Boar"},{name:"C", value:"Cat"}]

Url encode the above json like this: %5B%7Bname%3A%22A%22%2C+value%3A%22Anteater%22%7D%2C%7Bname%3A%22B%22%2C+value%3A%22Boar%22%7D%2C%7Bname%3A%22C%22%2C+value%3A%22Cat%22%7D%5D

The actual parameter should be thus:  /cgi-bin/UCEditor?merchantId=DEMO&props_json=%5B%7Bname%3A%22A%22%2C+value%3A%22Anteater%22%7D%2C%7Bname%3A%22B%22%2C+value%3A%22Boar%22%7D%2C%7Bname%3A%22C%22%2C+value%3A%22Cat%22%7D%5D


Once added, these parameters may be accessed easily through the UltraCart provided SDKs.  Here is one such example from our PHP library:

https://github.com/UltraCart/rest_api_v2_sdk_php/blob/master/lib/models/CartProperty.php

and more importantly, once the cart becomes an order, as an order property

https://github.com/UltraCart/rest_api_v2_sdk_php/blob/master/lib/models/OrderProperty.php

...