Skip to main content

NewStore SFCC Integration API (1.0.0)

Download OpenAPI specification:Download

Description

Provides integration between SalesForce Commerce Cloud and NewStore.

Create and Config a New Job

Create a new Catalog Export job

Create a new Catalog Export job and returns the URL for its input location.

Request Body schema: application/json
job_id
required
string
execution_id
required
string
site_id
required
string
cartridge_version
required
string

Responses

Request samples

Content type
application/json
{
  • "job_id": "string",
  • "execution_id": "string",
  • "site_id": "string",
  • "cartridge_version": "string"
}

Create a new Pricebook Export job

Create a new Pricebook Export job and returns the URL for its input location.

Request Body schema: application/json
job_id
required
string
execution_id
required
string
site_id
required
string
cartridge_version
required
string

Responses

Request samples

Content type
application/json
{
  • "job_id": "string",
  • "execution_id": "string",
  • "site_id": "string",
  • "cartridge_version": "string"
}

Get job config for an order export

Get job config for an order export. Returns the URL for its input location.

Request Body schema: application/json
job_id
required
string
execution_id
required
string
site_id
required
string
cartridge_version
required
string

Responses

Request samples

Content type
application/json
{
  • "job_id": "string",
  • "execution_id": "string",
  • "site_id": "string",
  • "cartridge_version": "string"
}

Response samples

Content type
application/json
{
  • "upload_url": "string"
}

Get job config for a inventory import

Returns the URL for its input location.

Request Body schema: application/json
job_id
required
string
execution_id
required
string
site_id
required
string
cartridge_version
required
string

Responses

Request samples

Content type
application/json
{
  • "job_id": "string",
  • "execution_id": "string",
  • "site_id": "string",
  • "cartridge_version": "string"
}

Response samples

Content type
application/json
{
  • "upload_url": "string"
}

Inventory import callback

Notify Callback from SFCC after successful inventory import

Request Body schema: application/json
job_id
required
string
execution_id
required
string
site_id
required
string
cartridge_version
required
string
custom
required
object

Responses

Request samples

Content type
application/json
{
  • "job_id": "string",
  • "execution_id": "string",
  • "site_id": "string",
  • "cartridge_version": "string",
  • "custom": { }
}

Start the availability export from NS

Start the availability export from NS

Request Body schema: application/json
job_id
required
string
execution_id
required
string
site_id
required
string
cartridge_version
required
string
custom
required
object

Responses

Request samples

Content type
application/json
{
  • "job_id": "string",
  • "execution_id": "string",
  • "site_id": "string",
  • "cartridge_version": "string",
  • "custom": { }
}

Job History

Shows a filterable list of created import jobs.

Returns a JSON object containing a jobs[] list.
If the result has more than one page, the response will also contain a nextPage hash.

Pagination:

If the nextPage hash is returned, it means we have more than one page.
To fetch the next page, call this endpoint again with the hash as a query parameter.
Example: /job_history?nextPage=PASTE_THE_HASH_HERE.

Filtering:

This endpoint supports the following filters:

  • entity (catalog, pricebook, order, availability, inventory) Example: /job_history?entity=catalog
  • status (pending, running, finished, failed) Example: /job_history?status=pending

query Parameters
entity
string
Enum: "catalog" "pricebook" "order" "availability" "inventory"
status
string
Enum: "pending" "running" "finished" "failed" "skipped"
nextPage
string

Responses

Response samples

Content type
application/json
{
  • "jobs": {
    },
  • "nextPage": "string"
}

Import job details

Shows information about a specific import job with a link for its logs.

path Parameters
uuid
required
string

Responses

Response samples

Content type
application/json
{
  • "uuid": "string",
  • "entity": "catalog",
  • "createdAt": "string",
  • "status": "pending",
  • "message": "string",
  • "catalogImportId": "string",
  • "metadata": {
    },
  • "links": {
    },
  • "statusHistory": [
    ],
  • "catalogMappingContext": {
    }
}

Get import job logs

Downloads the logs generated by an import job.

path Parameters
uuid
required
string

Responses

Downloads the input file provided.

Redirects to a pre-signed S3 URL to download the desired input or output file.

path Parameters
uuid
required
string
fileSourceType
required
string
Enum: "input" "output"

Responses

OCAPI credentials

Store credentials for OCAPI access

Allows the provided credentials to be stored securely, and then used for calls to OCAPI. Either to read data from the API or to start job executions. The availability import from NewStore to SFCC requires these credentials to be set.

Request Body schema: application/json
client_id
required
string

OCAPI client ID. Note for an SFCC sandbox instance, a value of "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" can be used.

client_secret
required
string

OCAPI client secret. Note for an SFCC sandbox instance, a value of "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" can be used.

Responses

Request samples

Content type
application/json
{
  • "client_id": "string",
  • "client_secret": "string"
}

Checkout Options

Get routing options from the NewStore Platform.

Allows to route an order from a store.

Request Body schema: application/json
required
object

An array of flat items from the shopping bag.

required
object
  The strategy used to route the order. If no value is specified, the default strategy is
  used and the order is routed to the best location based on the fulfillment configuration.
service_levels
Array of strings
Array of objects (RoutingOptionsRequestShippingAddress)

Responses

Request samples

Content type
application/json
{
  • "shopping_cart": {
    },
  • "routing_strategy": {
    },
  • "service_levels": [
    ],
  • "shipping_address": [
    ]
}

Response samples

Content type
application/json
{
  • "items": [
    ]
}

Get in-store pickup options from the NewStore Platform.

Allows collecting an order from a store.

Request Body schema: application/json
required
Array of objects (InStorePickupOptionsRequestBag)
required
object

A reference geo-location. For example, the location of the customer.

required
object

In-store pickup options request parameters.

Responses

Request samples

Content type
application/json
{
  • "bag": [
    ],
  • "location": {
    },
  • "options": {
    }
}

Response samples

Content type
application/json
{
  • "items": [
    ]
}

Mapping Config

Store mapping config for a catalog.

Stores the mapping config for a particular catalog, which then will be used for the transformation from the SFCC XML to NewStore JSON format.

Request Body schema: application/json
sfcc_catalog_id
required
string

The Catalog ID as defined in SalesForce Commerce Cloud. This ID is read when processing the uploaded input file and used to retrieve the associated mapping config.

required
object (CatalogMappingConfigClassDTO)

Responses

Request samples

Content type
application/json
{
  • "sfcc_catalog_id": "string",
  • "config": {
    }
}

Get all catalog mapping configurations for a tenant.

Retrives all catalog mapping configurations for a particular tenant. These will be used for the transformation from the SFCC XML to NewStore JSON format.

Responses

Store mapping config for a pricebook import.

Stores the mapping config for pricebook imports, which then will be used for the transformation from SFCC XML to NewStore JSON.

Request Body schema: application/json
config
required
object

Responses

Request samples

Content type
application/json
{
  • "config": { }
}

Get all pricebook mapping configurations for a tenant.

Retrive all pricebook mapping configurations for a particular tenant. These will be used for the transformation from the SFCC XML to NewStore JSON format.

Responses

Store mapping config for a availability.

Stores the mapping config for a particular availability list, which then will be used for the transformation from NewStore JSON format to SFCC XML.

Request Body schema: application/json
inventory_list_id
required
string
config
required
object

Responses

Request samples

Content type
application/json
{
  • "inventory_list_id": "string",
  • "config": { }
}

Get all availability mapping configurations for a tenant.

Retrive all availability mapping configurations for a particular tenant. These will be used for the transformation from the SFCC XML to NewStore JSON format.

Responses

Store mapping config for inventory lists.

Stores the mapping config for a particular inventory list, which then will be used for the transformation from SFCC XML to NewStore JSON format.

Request Body schema: application/json
inventory_list_id
required
string
config
required
object

Responses

Request samples

Content type
application/json
{
  • "inventory_list_id": "string",
  • "config": { }
}

Get all inventory mapping configurations for a tenant.

Retrive all inventory mapping configurations for a particular tenant. These will be used for the transformation from the SFCC XML to NewStore JSON format.

Responses

Mapping Script

Store mapping script for a catalog.

Stores the mapping for a catalog.

query Parameters
sfcc_catalog_id
required
string

Responses

Store mapping script for an order.

Stores the mapping script for an order.

Responses

Get the latest order mapping script

Get the latest order mapping script

Responses