All URIs are relative to https://api.ordercloud.io/v1
Method | HTTP request | Description |
---|---|---|
Create | POST /products | |
Delete | DELETE /products/{productID} | |
DeleteAssignment | DELETE /products/{productID}/assignments/{buyerID} | |
GenerateVariants | POST /products/{productID}/variants/generate | |
Get | GET /products/{productID} | |
GetVariant | GET /products/{productID}/variants/{variantID} | |
List | GET /products | |
ListAssignments | GET /products/assignments | |
ListSpecs | GET /products/{productID}/specs | |
ListSuppliers | GET /products/{productID}/suppliers | |
ListVariants | GET /products/{productID}/variants | |
Patch | PATCH /products/{productID} | |
PatchVariant | PATCH /products/{productID}/variants/{variantID} | |
RemoveSupplier | DELETE /products/{productID}/suppliers/{supplierID} | |
Save | PUT /products/{productID} | |
SaveAssignment | POST /products/assignments | |
SaveSupplier | PUT /products/{productID}/suppliers/{supplierID} | |
SaveVariant | PUT /products/{productID}/variants/{variantID} |
Product Create(product)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var product = new OrderCloud.Product(); // Product |
apiInstance.Create(product).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
product | Product |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Delete(productID)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
apiInstance.Delete(productID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
DeleteAssignment(productID, buyerID, opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var buyerID = "buyerID_example"; // String | ID of the buyer.
var opts = {
'userID': "userID_example", // String | ID of the user.
'userGroupID': "userGroupID_example" // String | ID of the user group.
};
apiInstance.DeleteAssignment(productID, buyerID, opts).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
buyerID | String | ID of the buyer. | |
userID | String | ID of the user. | [optional] |
userGroupID | String | ID of the user group. | [optional] |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Product GenerateVariants(productID, opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var opts = {
'overwriteExisting': true // Boolean | Overwrite existing of the product.
};
apiInstance.GenerateVariants(productID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
overwriteExisting | Boolean | Overwrite existing of the product. | [optional] |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Product Get(productID)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
apiInstance.Get(productID).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Variant GetVariant(productID, variantID)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var variantID = "variantID_example"; // String | ID of the variant.
apiInstance.GetVariant(productID, variantID).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
variantID | String | ID of the variant. |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListProduct List(opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var opts = {
'catalogID': "catalogID_example", // String | ID of the catalog.
'categoryID': "categoryID_example", // String | ID of the category.
'supplierID': "supplierID_example", // String | ID of the supplier.
'search': "search_example", // String | Word or phrase to search for.
'searchOn': "searchOn_example", // String | Comma-delimited list of fields to search on.
'sortBy': "sortBy_example", // String | Comma-delimited list of fields to sort by.
'page': 56, // Number | Page of results to return. Default: 1
'pageSize': 56, // Number | Number of results to return per page. Default: 20, max: 100.
'filters': {key: "filters_example"} // {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???'
};
apiInstance.List(opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
catalogID | String | ID of the catalog. | [optional] |
categoryID | String | ID of the category. | [optional] |
supplierID | String | ID of the supplier. | [optional] |
search | String | Word or phrase to search for. | [optional] |
searchOn | String | Comma-delimited list of fields to search on. | [optional] |
sortBy | String | Comma-delimited list of fields to sort by. | [optional] |
page | Number | Page of results to return. Default: 1 | [optional] |
pageSize | Number | Number of results to return per page. Default: 20, max: 100. | [optional] |
filters | {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???' | [optional] |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListProductAssignment ListAssignments(opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var opts = {
'productID': "productID_example", // String | ID of the product.
'priceScheduleID': "priceScheduleID_example", // String | ID of the price schedule.
'buyerID': "buyerID_example", // String | ID of the buyer.
'userID': "userID_example", // String | ID of the user.
'userGroupID': "userGroupID_example", // String | ID of the user group.
'level': "level_example", // String | Level of the product assignment. Possible values: User, Group, Company.
'page': 56, // Number | Page of results to return. Default: 1
'pageSize': 56 // Number | Number of results to return per page. Default: 20, max: 100.
};
apiInstance.ListAssignments(opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | [optional] |
priceScheduleID | String | ID of the price schedule. | [optional] |
buyerID | String | ID of the buyer. | [optional] |
userID | String | ID of the user. | [optional] |
userGroupID | String | ID of the user group. | [optional] |
level | String | Level of the product assignment. Possible values: User, Group, Company. | [optional] |
page | Number | Page of results to return. Default: 1 | [optional] |
pageSize | Number | Number of results to return per page. Default: 20, max: 100. | [optional] |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListSpec ListSpecs(productID, opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var opts = {
'search': "search_example", // String | Word or phrase to search for.
'searchOn': "searchOn_example", // String | Comma-delimited list of fields to search on.
'sortBy': "sortBy_example", // String | Comma-delimited list of fields to sort by.
'page': 56, // Number | Page of results to return. Default: 1
'pageSize': 56, // Number | Number of results to return per page. Default: 20, max: 100.
'filters': {key: "filters_example"} // {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???'
};
apiInstance.ListSpecs(productID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
search | String | Word or phrase to search for. | [optional] |
searchOn | String | Comma-delimited list of fields to search on. | [optional] |
sortBy | String | Comma-delimited list of fields to sort by. | [optional] |
page | Number | Page of results to return. Default: 1 | [optional] |
pageSize | Number | Number of results to return per page. Default: 20, max: 100. | [optional] |
filters | {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???' | [optional] |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListSupplier ListSuppliers(productID, opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var opts = {
'search': "search_example", // String | Word or phrase to search for.
'searchOn': "searchOn_example", // String | Comma-delimited list of fields to search on.
'sortBy': "sortBy_example", // String | Comma-delimited list of fields to sort by.
'page': 56, // Number | Page of results to return. Default: 1
'pageSize': 56, // Number | Number of results to return per page. Default: 20, max: 100.
'filters': {key: "filters_example"} // {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???'
};
apiInstance.ListSuppliers(productID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
search | String | Word or phrase to search for. | [optional] |
searchOn | String | Comma-delimited list of fields to search on. | [optional] |
sortBy | String | Comma-delimited list of fields to sort by. | [optional] |
page | Number | Page of results to return. Default: 1 | [optional] |
pageSize | Number | Number of results to return per page. Default: 20, max: 100. | [optional] |
filters | {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???' | [optional] |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListVariant ListVariants(productID, opts)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var opts = {
'search': "search_example", // String | Word or phrase to search for.
'searchOn': "searchOn_example", // String | Comma-delimited list of fields to search on.
'sortBy': "sortBy_example", // String | Comma-delimited list of fields to sort by.
'page': 56, // Number | Page of results to return. Default: 1
'pageSize': 56, // Number | Number of results to return per page. Default: 20, max: 100.
'filters': {key: "filters_example"} // {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???'
};
apiInstance.ListVariants(productID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
search | String | Word or phrase to search for. | [optional] |
searchOn | String | Comma-delimited list of fields to search on. | [optional] |
sortBy | String | Comma-delimited list of fields to sort by. | [optional] |
page | Number | Page of results to return. Default: 1 | [optional] |
pageSize | Number | Number of results to return per page. Default: 20, max: 100. | [optional] |
filters | {String: String} | Any additional key/value pairs passed in the query string are interpretted as filters. Valid keys are top-level properties of the returned model or 'xp.???' | [optional] |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Product Patch(productID, partialProduct)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var partialProduct = new OrderCloud.Product(); // Product |
apiInstance.Patch(productID, partialProduct).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
partialProduct | Product |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Variant PatchVariant(productID, variantID, partialVariant)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var variantID = "variantID_example"; // String | ID of the variant.
var partialVariant = new OrderCloud.Variant(); // Variant |
apiInstance.PatchVariant(productID, variantID, partialVariant).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
variantID | String | ID of the variant. | |
partialVariant | Variant |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
RemoveSupplier(productID, supplierID)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var supplierID = "supplierID_example"; // String | ID of the supplier.
apiInstance.RemoveSupplier(productID, supplierID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
supplierID | String | ID of the supplier. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Product Save(productID, product)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var product = new OrderCloud.Product(); // Product |
apiInstance.Save(productID, product).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
product | Product |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SaveAssignment(productAssignment)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productAssignment = new OrderCloud.ProductAssignment(); // ProductAssignment |
apiInstance.SaveAssignment(productAssignment).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productAssignment | ProductAssignment |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SaveSupplier(productID, supplierID)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var supplierID = "supplierID_example"; // String | ID of the supplier.
apiInstance.SaveSupplier(productID, supplierID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
supplierID | String | ID of the supplier. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Variant SaveVariant(productID, variantID, variant)
var OrderCloud = require('OrderCloud');
var defaultClient = OrderCloud.Sdk.default;
// Configure OAuth2 access token for authorization: oauth2
var oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
var apiInstance = new OrderCloud.Products();
var productID = "productID_example"; // String | ID of the product.
var variantID = "variantID_example"; // String | ID of the variant.
var variant = new OrderCloud.Variant(); // Variant |
apiInstance.SaveVariant(productID, variantID, variant).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
productID | String | ID of the product. | |
variantID | String | ID of the variant. | |
variant | Variant |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json