Skip to content

Latest commit

 

History

History
2026 lines (1327 loc) · 60.4 KB

File metadata and controls

2026 lines (1327 loc) · 60.4 KB

OrderCloud.Me

All URIs are relative to https://api.ordercloud.io/v1

Method HTTP request Description
CreateAddress POST /me/addresses
CreateCreditCard POST /me/creditcards
DeleteAddress DELETE /me/addresses/{addressID}
DeleteCreditCard DELETE /me/creditcards/{creditcardID}
Get GET /me
GetAddress GET /me/addresses/{addressID}
GetCatalog GET /me/catalogs/{catalogID}
GetCategory GET /me/categories/{categoryID}
GetCreditCard GET /me/creditcards/{creditcardID}
GetProduct GET /me/products/{productID}
GetPromotion GET /me/promotions/{promotionID}
GetShipment GET /me/shipments/{shipmentID}
GetSpec GET /me/products/{productID}/specs/{specID}
GetSpendingAccount GET /me/spendingaccounts/{spendingAccountID}
ListAddresses GET /me/addresses
ListApprovableOrders GET /me/orders/approvable
ListCatalogs GET /me/catalogs
ListCategories GET /me/categories
ListCostCenters GET /me/costcenters
ListCreditCards GET /me/creditcards
ListOrders GET /me/orders
ListProducts GET /me/products
ListPromotions GET /me/promotions
ListShipmentItems GET /me/shipments/{shipmentID}/items
ListShipments GET /me/shipments
ListSpecs GET /me/products/{productID}/specs
ListSpendingAccounts GET /me/spendingAccounts
ListUserGroups GET /me/usergroups
Patch PATCH /me
PatchAddress PATCH /me/addresses/{addressID}
PatchCreditCard PATCH /me/creditcards/{creditcardID}
Register PUT /me/register
ResetPasswordByToken POST /me/password
Save PUT /me
SaveAddress PUT /me/addresses/{addressID}
SaveCreditCard PUT /me/creditcards/{creditcardID}
TransferAnonUserOrder PUT /me/orders

CreateAddress

BuyerAddress CreateAddress(buyerAddress)

Example

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.Me();

var buyerAddress = new OrderCloud.BuyerAddress(); // BuyerAddress | 

apiInstance.CreateAddress(buyerAddress).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
buyerAddress BuyerAddress

Return type

BuyerAddress

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

CreateCreditCard

BuyerCreditCard CreateCreditCard(buyerCreditCard)

Example

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.Me();

var buyerCreditCard = new OrderCloud.BuyerCreditCard(); // BuyerCreditCard | 

apiInstance.CreateCreditCard(buyerCreditCard).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
buyerCreditCard BuyerCreditCard

Return type

BuyerCreditCard

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

DeleteAddress

DeleteAddress(addressID)

Example

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.Me();

var addressID = "addressID_example"; // String | ID of the address.

apiInstance.DeleteAddress(addressID).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
addressID String ID of the address.

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

DeleteCreditCard

DeleteCreditCard(creditcardID)

Example

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.Me();

var creditcardID = "creditcardID_example"; // String | ID of the creditcard.

apiInstance.DeleteCreditCard(creditcardID).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
creditcardID String ID of the creditcard.

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

Get

MeUser Get()

Example

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.Me();
apiInstance.Get().then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

This endpoint does not need any parameter.

Return type

MeUser

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetAddress

BuyerAddress GetAddress(addressID)

Example

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.Me();

var addressID = "addressID_example"; // String | ID of the address.

apiInstance.GetAddress(addressID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
addressID String ID of the address.

Return type

BuyerAddress

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetCatalog

Catalog GetCatalog(catalogID)

Example

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.Me();

var catalogID = "catalogID_example"; // String | ID of the catalog.

apiInstance.GetCatalog(catalogID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
catalogID String ID of the catalog.

Return type

Catalog

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetCategory

Category GetCategory(categoryID, catalogID)

Example

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.Me();

var categoryID = "categoryID_example"; // String | ID of the category.

var catalogID = "catalogID_example"; // String | ID of the catalog.

apiInstance.GetCategory(categoryID, catalogID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
categoryID String ID of the category.
catalogID String ID of the catalog.

Return type

Category

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetCreditCard

BuyerCreditCard GetCreditCard(creditcardID)

Example

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.Me();

var creditcardID = "creditcardID_example"; // String | ID of the creditcard.

apiInstance.GetCreditCard(creditcardID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
creditcardID String ID of the creditcard.

Return type

BuyerCreditCard

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetProduct

BuyerProduct GetProduct(productID)

Example

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.Me();

var productID = "productID_example"; // String | ID of the product.

apiInstance.GetProduct(productID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
productID String ID of the product.

Return type

BuyerProduct

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetPromotion

Promotion GetPromotion(promotionID)

Example

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.Me();

var promotionID = "promotionID_example"; // String | ID of the promotion.

apiInstance.GetPromotion(promotionID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
promotionID String ID of the promotion.

Return type

Promotion

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetShipment

Shipment GetShipment(shipmentID)

Example

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.Me();

var shipmentID = "shipmentID_example"; // String | ID of the shipment.

apiInstance.GetShipment(shipmentID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
shipmentID String ID of the shipment.

Return type

Shipment

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetSpec

Spec GetSpec(productID, specID, opts)

Example

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.Me();

var productID = "productID_example"; // String | ID of the product.

var specID = "specID_example"; // String | ID of the spec.

var opts = { 
  'catalogID': "catalogID_example" // String | ID of the catalog.
};
apiInstance.GetSpec(productID, specID, opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
productID String ID of the product.
specID String ID of the spec.
catalogID String ID of the catalog. [optional]

Return type

Spec

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

GetSpendingAccount

SpendingAccount GetSpendingAccount(spendingAccountID)

Example

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.Me();

var spendingAccountID = "spendingAccountID_example"; // String | ID of the spending account.

apiInstance.GetSpendingAccount(spendingAccountID).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
spendingAccountID String ID of the spending account.

Return type

SpendingAccount

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListAddresses

ListBuyerAddress ListAddresses(opts)

Example

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.Me();

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.ListAddresses(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListBuyerAddress

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListApprovableOrders

ListOrder ListApprovableOrders(opts)

Example

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.Me();

var opts = { 
  'from': "from_example", // String | Lower bound of date range that the order was created (if outgoing) or submitted (if incoming).
  'to': "to_example", // String | Upper bound of date range that the order was created (if outgoing) or submitted (if incoming).
  '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.ListApprovableOrders(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
from String Lower bound of date range that the order was created (if outgoing) or submitted (if incoming). [optional]
to String Upper bound of date range that the order was created (if outgoing) or submitted (if incoming). [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]

Return type

ListOrder

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListCatalogs

ListCatalog ListCatalogs(opts)

Example

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.Me();

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.ListCatalogs(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListCatalog

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListCategories

ListCategory ListCategories(opts)

Example

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.Me();

var opts = { 
  'depth': "depth_example", // String | Indicates how deep down the hierarchy to return results. Valid values are a number of 1 or greater, or 'all'. Relative to ParentID if specified. Default is 1.
  'catalogID': "catalogID_example", // String | ID of the catalog.
  'productID': "productID_example", // String | ID of the product.
  '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.ListCategories(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
depth String Indicates how deep down the hierarchy to return results. Valid values are a number of 1 or greater, or 'all'. Relative to ParentID if specified. Default is 1. [optional]
catalogID String ID of the catalog. [optional]
productID String ID of the product. [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]

Return type

ListCategory

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListCostCenters

ListCostCenter ListCostCenters(opts)

Example

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.Me();

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.ListCostCenters(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListCostCenter

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListCreditCards

ListBuyerCreditCard ListCreditCards(opts)

Example

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.Me();

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.ListCreditCards(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListBuyerCreditCard

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListOrders

ListOrder ListOrders(opts)

Example

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.Me();

var opts = { 
  'from': "from_example", // String | Lower bound of date range that the order was created (if outgoing) or submitted (if incoming).
  'to': "to_example", // String | Upper bound of date range that the order was created (if outgoing) or submitted (if incoming).
  '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.ListOrders(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
from String Lower bound of date range that the order was created (if outgoing) or submitted (if incoming). [optional]
to String Upper bound of date range that the order was created (if outgoing) or submitted (if incoming). [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]

Return type

ListOrder

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListProducts

ListBuyerProduct ListProducts(opts)

Example

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.Me();

var opts = { 
  'catalogID': "catalogID_example", // String | ID of the catalog.
  'categoryID': "categoryID_example", // String | ID of the category.
  'depth': "depth_example", // String | Indicates how deep down the category hierarchy to return results. Valid values are a number of 1 or greater, or 'all'. Relative to CategoryID if specified, otherwise top level of the Catalog. Default is 'all'.
  '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.ListProducts(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
catalogID String ID of the catalog. [optional]
categoryID String ID of the category. [optional]
depth String Indicates how deep down the category hierarchy to return results. Valid values are a number of 1 or greater, or 'all'. Relative to CategoryID if specified, otherwise top level of the Catalog. Default is 'all'. [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]

Return type

ListBuyerProduct

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListPromotions

ListPromotion ListPromotions(opts)

Example

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.Me();

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.ListPromotions(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListPromotion

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListShipmentItems

ListShipmentItem ListShipmentItems(shipmentID, opts)

Example

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.Me();

var shipmentID = "shipmentID_example"; // String | ID of the shipment.

var opts = { 
  'orderID': "orderID_example", // String | ID of the order.
  '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.ListShipmentItems(shipmentID, opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
shipmentID String ID of the shipment.
orderID String ID of the order. [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]

Return type

ListShipmentItem

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListShipments

ListShipment ListShipments(opts)

Example

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.Me();

var opts = { 
  'orderID': "orderID_example", // String | ID of the order.
  '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.ListShipments(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
orderID String ID of the order. [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]

Return type

ListShipment

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListSpecs

ListSpec ListSpecs(productID, opts)

Example

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.Me();

var productID = "productID_example"; // String | ID of the product.

var opts = { 
  'catalogID': "catalogID_example", // String | ID of the catalog.
  '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);
});

Parameters

Name Type Description Notes
productID String ID of the product.
catalogID String ID of the catalog. [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]

Return type

ListSpec

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListSpendingAccounts

ListSpendingAccount ListSpendingAccounts(opts)

Example

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.Me();

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.ListSpendingAccounts(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListSpendingAccount

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ListUserGroups

ListUserGroup ListUserGroups(opts)

Example

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.Me();

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.ListUserGroups(opts).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

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]

Return type

ListUserGroup

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

Patch

MeUser Patch(partialMeUser)

Example

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.Me();

var partialMeUser = new OrderCloud.MeUser(); // MeUser | 

apiInstance.Patch(partialMeUser).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
partialMeUser MeUser

Return type

MeUser

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

PatchAddress

PatchAddress(addressID, partialBuyerAddress)

Example

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.Me();

var addressID = "addressID_example"; // String | ID of the address.

var partialBuyerAddress = new OrderCloud.BuyerAddress(); // BuyerAddress | 

apiInstance.PatchAddress(addressID, partialBuyerAddress).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
addressID String ID of the address.
partialBuyerAddress BuyerAddress

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

PatchCreditCard

PatchCreditCard(creditcardID, partialBuyerCreditCard)

Example

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.Me();

var creditcardID = "creditcardID_example"; // String | ID of the creditcard.

var partialBuyerCreditCard = new OrderCloud.BuyerCreditCard(); // BuyerCreditCard | 

apiInstance.PatchCreditCard(creditcardID, partialBuyerCreditCard).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
creditcardID String ID of the creditcard.
partialBuyerCreditCard BuyerCreditCard

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

Register

AccessTokenBasic Register(anonUserToken, meUser)

Example

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.Me();

var anonUserToken = "anonUserToken_example"; // String | Anon user token of the user.

var meUser = new OrderCloud.MeUser(); // MeUser | 

apiInstance.Register(anonUserToken, meUser).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
anonUserToken String Anon user token of the user.
meUser MeUser

Return type

AccessTokenBasic

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

ResetPasswordByToken

ResetPasswordByToken(tokenPasswordReset)

Example

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.Me();

var tokenPasswordReset = new OrderCloud.TokenPasswordReset(); // TokenPasswordReset | 

apiInstance.ResetPasswordByToken(tokenPasswordReset).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
tokenPasswordReset TokenPasswordReset

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

Save

MeUser Save(meUser)

Example

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.Me();

var meUser = new OrderCloud.MeUser(); // MeUser | 

apiInstance.Save(meUser).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
meUser MeUser

Return type

MeUser

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

SaveAddress

BuyerAddress SaveAddress(addressID, buyerAddress)

Example

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.Me();

var addressID = "addressID_example"; // String | ID of the address.

var buyerAddress = new OrderCloud.BuyerAddress(); // BuyerAddress | 

apiInstance.SaveAddress(addressID, buyerAddress).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
addressID String ID of the address.
buyerAddress BuyerAddress

Return type

BuyerAddress

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

SaveCreditCard

BuyerCreditCard SaveCreditCard(creditcardID, buyerCreditCard)

Example

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.Me();

var creditcardID = "creditcardID_example"; // String | ID of the creditcard.

var buyerCreditCard = new OrderCloud.BuyerCreditCard(); // BuyerCreditCard | 

apiInstance.SaveCreditCard(creditcardID, buyerCreditCard).then(function(data) {
  console.log('API called successfully. Returned data: ' + data);
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
creditcardID String ID of the creditcard.
buyerCreditCard BuyerCreditCard

Return type

BuyerCreditCard

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json

TransferAnonUserOrder

TransferAnonUserOrder(anonUserToken)

Example

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.Me();

var anonUserToken = "anonUserToken_example"; // String | Anon user token of the me.

apiInstance.TransferAnonUserOrder(anonUserToken).then(function() {
  console.log('API called successfully.');
}, function(error) {
  console.error(error);
});

Parameters

Name Type Description Notes
anonUserToken String Anon user token of the me.

Return type

null (empty response body)

Authorization

oauth2

HTTP request headers

  • Content-Type: application/json, text/plain; charset=utf-8
  • Accept: application/json