All URIs are relative to https://api.ordercloud.io/v1
Method | HTTP request | Description |
---|---|---|
Create | POST /specs | |
CreateOption | POST /specs/{specID}/options | |
Delete | DELETE /specs/{specID} | |
DeleteOption | DELETE /specs/{specID}/options/{optionID} | |
DeleteProductAssignment | DELETE /specs/{specID}/productassignments/{productID} | |
Get | GET /specs/{specID} | |
GetOption | GET /specs/{specID}/options/{optionID} | |
List | GET /specs | |
ListOptions | GET /specs/{specID}/options | |
ListProductAssignments | GET /specs/productassignments | |
Patch | PATCH /specs/{specID} | |
PatchOption | PATCH /specs/{specID}/options/{optionID} | |
Save | PUT /specs/{specID} | |
SaveOption | PUT /specs/{specID}/options/{optionID} | |
SaveProductAssignment | POST /specs/productassignments |
Spec Create(spec)
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.Specs();
var spec = new OrderCloud.Spec(); // Spec |
apiInstance.Create(spec).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
spec | Spec |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SpecOption CreateOption(specID, specOption)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var specOption = new OrderCloud.SpecOption(); // SpecOption |
apiInstance.CreateOption(specID, specOption).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
specOption | SpecOption |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Delete(specID)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
apiInstance.Delete(specID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
DeleteOption(specID, optionID)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var optionID = "optionID_example"; // String | ID of the option.
apiInstance.DeleteOption(specID, optionID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
optionID | String | ID of the option. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
DeleteProductAssignment(specID, 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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var productID = "productID_example"; // String | ID of the product.
apiInstance.DeleteProductAssignment(specID, productID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
productID | String | ID of the product. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Spec Get(specID)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
apiInstance.Get(specID).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SpecOption GetOption(specID, optionID)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var optionID = "optionID_example"; // String | ID of the option.
apiInstance.GetOption(specID, optionID).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
optionID | String | ID of the option. |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListSpec 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.Specs();
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.List(opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
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
ListSpecOption ListOptions(specID, 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.Specs();
var specID = "specID_example"; // String | ID of the spec.
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.ListOptions(specID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
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
ListSpecProductAssignment ListProductAssignments(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.Specs();
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.ListProductAssignments(opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
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
Spec Patch(specID, partialSpec)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var partialSpec = new OrderCloud.Spec(); // Spec |
apiInstance.Patch(specID, partialSpec).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
partialSpec | Spec |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SpecOption PatchOption(specID, optionID, partialSpecOption)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var optionID = "optionID_example"; // String | ID of the option.
var partialSpecOption = new OrderCloud.SpecOption(); // SpecOption |
apiInstance.PatchOption(specID, optionID, partialSpecOption).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
optionID | String | ID of the option. | |
partialSpecOption | SpecOption |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Spec Save(specID, spec)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var spec = new OrderCloud.Spec(); // Spec |
apiInstance.Save(specID, spec).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
spec | Spec |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SpecOption SaveOption(specID, optionID, specOption)
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.Specs();
var specID = "specID_example"; // String | ID of the spec.
var optionID = "optionID_example"; // String | ID of the option.
var specOption = new OrderCloud.SpecOption(); // SpecOption |
apiInstance.SaveOption(specID, optionID, specOption).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specID | String | ID of the spec. | |
optionID | String | ID of the option. | |
specOption | SpecOption |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SaveProductAssignment(specProductAssignment)
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.Specs();
var specProductAssignment = new OrderCloud.SpecProductAssignment(); // SpecProductAssignment |
apiInstance.SaveProductAssignment(specProductAssignment).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
specProductAssignment | SpecProductAssignment |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json