All URIs are relative to https://api.ordercloud.io/v1
Method | HTTP request | Description |
---|---|---|
Create | POST /buyers/{buyerID}/addresses | |
Delete | DELETE /buyers/{buyerID}/addresses/{addressID} | |
DeleteAssignment | DELETE /buyers/{buyerID}/addresses/{addressID}/assignments | |
Get | GET /buyers/{buyerID}/addresses/{addressID} | |
List | GET /buyers/{buyerID}/addresses | |
ListAssignments | GET /buyers/{buyerID}/addresses/assignments | |
Patch | PATCH /buyers/{buyerID}/addresses/{addressID} | |
Save | PUT /buyers/{buyerID}/addresses/{addressID} | |
SaveAssignment | POST /buyers/{buyerID}/addresses/assignments |
Address Create(buyerID, address)
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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var address = new OrderCloud.Address(); // Address |
apiInstance.Create(buyerID, address).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
address | Address |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Delete(buyerID, addressID)
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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var addressID = "addressID_example"; // String | ID of the address.
apiInstance.Delete(buyerID, addressID).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressID | String | ID of the address. |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
DeleteAssignment(buyerID, addressID, 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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var addressID = "addressID_example"; // String | ID of the address.
var opts = {
'userID': "userID_example", // String | ID of the user.
'userGroupID': "userGroupID_example" // String | ID of the user group.
};
apiInstance.DeleteAssignment(buyerID, addressID, opts).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressID | String | ID of the address. | |
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
Address Get(buyerID, addressID)
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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var addressID = "addressID_example"; // String | ID of the address.
apiInstance.Get(buyerID, addressID).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressID | String | ID of the address. |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
ListAddress List(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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
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(buyerID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
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
ListAddressAssignment ListAssignments(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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var opts = {
'addressID': "addressID_example", // String | ID of the address.
'userID': "userID_example", // String | ID of the user.
'userGroupID': "userGroupID_example", // String | ID of the user group.
'level': "level_example", // String | Level of the address assignment. Possible values: User, Group, Company.
'isShipping': true, // Boolean | Is shipping of the address assignment.
'isBilling': true, // Boolean | Is billing of the address assignment.
'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(buyerID, opts).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressID | String | ID of the address. | [optional] |
userID | String | ID of the user. | [optional] |
userGroupID | String | ID of the user group. | [optional] |
level | String | Level of the address assignment. Possible values: User, Group, Company. | [optional] |
isShipping | Boolean | Is shipping of the address assignment. | [optional] |
isBilling | Boolean | Is billing of the address assignment. | [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
Address Patch(buyerID, addressID, partialAddress)
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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var addressID = "addressID_example"; // String | ID of the address.
var partialAddress = new OrderCloud.Address(); // Address |
apiInstance.Patch(buyerID, addressID, partialAddress).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressID | String | ID of the address. | |
partialAddress | Address |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
Address Save(buyerID, addressID, address)
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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var addressID = "addressID_example"; // String | ID of the address.
var address = new OrderCloud.Address(); // Address |
apiInstance.Save(buyerID, addressID, address).then(function(data) {
console.log('API called successfully. Returned data: ' + data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressID | String | ID of the address. | |
address | Address |
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json
SaveAssignment(buyerID, addressAssignment)
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.Addresses();
var buyerID = "buyerID_example"; // String | ID of the buyer.
var addressAssignment = new OrderCloud.AddressAssignment(); // AddressAssignment |
apiInstance.SaveAssignment(buyerID, addressAssignment).then(function() {
console.log('API called successfully.');
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
buyerID | String | ID of the buyer. | |
addressAssignment | AddressAssignment |
null (empty response body)
- Content-Type: application/json, text/plain; charset=utf-8
- Accept: application/json