Skip to main content
Vindicia Knowledge Center

Create a Product

Create a Product

Creates a new Product object.

Route (URL) Parameters

None.

Query Parameters

None.

Accepts

JSON A full Product object.

Returns

JSON A full Product object.

  • cURL
  • Java
Example Request
curl -X POST \
-u acaff38d462f9430d5cbcbaf:a575771fc679b9de \ 
-d ' {
    "object": "Product",
    "id": "prod_2234",
    "status": "Active",
    "tax_classification": "TaxExempt",
    "prices": [
        {
        "object": "ProductPrice",
        "amount": 2.00,
        "currency": "USD"
        }
    ]
}' "https://api.prodtest.vindicia.com/products"
The above command returns JSON structured like this:
{
    "object": "Product",
    "id": "prod_1234",
    "vid": "190828347a650eeca011ac8a6be550416d4cf9a0",
    "created": "2016-05-15T23:45:06-07:00",

    "descriptions": {
        "object": "List",
        "data": [
            {
            "object": "ProductDescription",
            "language": "EN",
            "description": "prod_1234"
            }
        ],
        "total_count": 1
    },

    "status": "Active",
    "tax_classification": "DownloadableElectronicData",

    "default_billing_plan": {`...`},

    "metadata": {
        "COA_CODE": "GNGX102"
    },

    "entitlements": {`...`},
    "credit_granted": {`...`},

    "prices": {
        "object": "List",
        "data": [
            {
            "object": "ProductPrice",
            "amount": 2,
            "currency": "USD"
            }
        ],
        "total_count": 1
    }
}
import com.vindicia.client.CashBox;

CashBox.apiKey = "acaff38d462f9430d5cbcbafa575771fc679b9de";

Map<string,> params = new HashMap<string,>();
params.put("tax_classification", "TaxExempt");
params.put("id",    "prod_1234");

Product.create(params);
The above command returns JSON structured like this:
{
    "object": "Product",
    "id": "prod_1234",
    "vid": "190828347a650eeca011ac8a6be550416d4cf9a0",
    "created": "2016-05-15T23:45:06-07:00",

    "descriptions": {
        "object": "List",
        "data": [
            {
            "object": "ProductDescription",
            "language": "EN",
            "description": "prod_1234"
            }
        ],
        "total_count": 1
    },

    "status": "Active",
    "tax_classification": "DownloadableElectronicData",

    "default_billing_plan": {`...`},

    "metadata": {
        "COA_CODE": "GNGX102"
    },

    "entitlements": {`...`},
    "credit_granted": {`...`},

    "prices": {
        "object": "List",
        "data": [
            {
            "object": "ProductPrice",
            "amount": 2,
            "currency": "USD"
            }
        ],
        "total_count": 1
    }
}

For Users

Learn More
For Users

Cashbox Features

Learn More
Cashbox Features
Back to Top