VPCart API: View

This View method will retrieve a single record based on provided parameters record id and fieldname(s) and tablename supplied in the Endpoint url.

View Endpoint URL and Request Parameters

POST  <VPCart site url>/cart_api/<table name>/view/


Example of request parameters in JSON:

{

      "id": "1",

      "fieldnames": "firstname,lastname,email"

}

<table name>

Mandatory parameter in View Endpoint url.
Please replace with the VPCart table name you want.

For the list of tables allowed to be included in this endpoint url, is stored in the config xapi_allowtables.

Default tables for config “xapi_allowtables” are :
blogs
categories

content

contentcategories

currencyvalues

customers

news

orders

products

shopcountries

shopstates

NOTE : Although you are able to enter any other VPCart table(s) into the list if you need, however we are strongly advise you to not enter other VPCart table(s) for security reasons.

id

Mandatory parameter. This is the table primary key field value.
Example if id 1 means to retrieve a record with ID = 1.

fieldnames

Optional parameter. If blank, will return a max of 200 fieldnames by default.
You can enter fieldnames of a related table specified in <table name> end point, separated by comma, eg. firstname,lastname,email.