Integrating With Demandware
encapsulate
A REST-based service can use intermediary components to reduce latency, enforce security, and ___________________ legacy systems.
status code
A response will contain a __________ _______________.
Exports orders (all or confirmed and paid) to a designated local directory.
Describe Export-Order.
stateless
Because RESTful services are ________________, each request-response conversation stands on its own. You can cache the information to conserve resources.
Service Framework
Because integrations can potentially share common data, they are often in contention for the same services. The ________ ____________ helps to prevent possible conflicts between these services. This can degrade overall site performance.
JSON
By default, REST services returns ______________if the format is not explicitly specified in the URL.
401; unauthorized
By default, no permission is granted and the Open Commerce API declines any client application request that does not have the appropriate permissions, returning an HTTP status of _________ (___________).
Exports specified price book into a designated local directory.
Describe Export-Pricebook.
The AbstractBaseService defines the workflow logic which results in calling a web service. It defines a set of abstract methods that are implemented later in the class hierarchy. It also handles errors conditions which can result in the implementation of the circuit breaker pattern. The remaining classes are used to tailor the class hierarchy for specific service type requests, such as HTTP, REST, XML over HTTP, and SOAP. These requests inherit some of the abstract methods defined in the AbstractBaseService object. In other words, the implementation of a new web service merely consists of adding a level to the hierarchy to customize the classes for the target service.
Define AbstractBaseService.
Remove a resource from the server.
Define DELETE.
Digital Store Solution
Define DSS.
When the credential type is set to DUMMY, no calls are made to the service. Instead, the service returns a predefined programmable response. In other words, the DUMMY setting allows you to simulate a response coming from an external service; even if the service is unavailable. This type of stub implementation facilitates the integration in two ways. First, you can continue moving forward with your implementation even if a third party service you may need to integrate with hasn't yet provided you with a test environment. Secondly, the DUMMY setting allows you to test edge cases easily. Sometimes test environments do not provide you with the level of services that a production system would. Using the DUMMY setting, you can simulate any kind of response, from any kind of service. As a result, you are able to test edge cases that you might not ordinarily be able to test.
Define DUMMY.
Supports upload and download of files such as XML and CSV, with Demandware acting as an FTP client for text or binary file transfer. You can also create an FTP client within your instance using the Demandware script class FTPClient.
Define FTP/sFTP.
Retrieve a specific resource(s) from the server.
Define GET.
Retrieve resource metadata.
Define HEAD.
Retrieve what the consumer is allowed to do with the resource.
Define OPTIONS.
Update a resource on the server, providing only changed attributes.
Define PATCH.
Create a new resource on the server.
Define POST.
Update a resource on the server, providing the entire resource.
Define PUT.
Representation State Transfer (REST) is a set of architectural principles by which you can design web services that focus on a system's resources, including how resource states are addressed and transferred over HTTP by a wide range of clients written in different languages.
Define REST.
Simple Object Access Protocol (SOAP) is an XML-based, extensible message envelope format, with 'bindings' to underlying protocols (such as HTTP, SMTP and XMPP). The WSDL (Web Services Definition Language) provides an extensible message envelope that provides the mechanism to implement these bindings.
Define SOAP.
Manages files and folders on Demandware servers. In addition, you can schedule batch jobs to occur once or according to a schedule using the Demandware Integration Framework. It provides a way to schedule, manage, and monitor jobs.
Define WebDAV.
Contains the pipeline that implements this component and a JSON object that configures that pipeline.
Define the object WorkflowComponentDefinition.
Contains the configuration data for a particular component.
Define the object WorkflowComponentInstance.
Contains a Workflow Schedule as defined by the user. This contains only data from the General portion of the screen.
Define the object WorkflowScheduleDefinition.
Contains the relationship between a Workflow Schedule and its Workflow Components.
Define the object WorkflowScheduleDefinitionWorkflowComponentDefinitionRelation.
Contains information about a particular run of a Workflow Schedule.
Define the object WorkflowScheduleInstance.
Removes and archives old files in specified folders.
Describe CleanUpFiles.
Prevents the workflow from executing when a configured date has passed (or until a specified date in the future has arrived). This can be useful to ensure that replication or other workflows do not impact the production system
Describe DateCondition.
Prevents the workflow from executing when a configured date and time has passed (or until a specified date and time in the future has arrived). This can be useful to ensure that replication or other workflows do not impact the production system performance.
Describe DateTimeCondition.
Exports a specified catalog into a designated local directory.
Describe Export-Catalog.
Rebuild configured indexes. This component can be useful after the import of a catalog for example.
Describe Rebuild indexes.
Imports from a designated WebDAV or (S)FTP location into Demandware.
Describe StandardComponents-DownloadFiles.
Imports any system or custom object from a designated local or remote directory via XML files that correspond to a specific naming pattern.
Describe StandardComponents-Import.
Prevents the workflow from executing when a configured time has passed (or until a specified time in the future has arrived). This can be useful to ensure that replication or other workflows do not impact the production system performance.
Describe TimeCondition.
Copies files to a local directory from a FTP-Location.
Describe Transfer From FTP.
Copies of files from a local directory to a FTP-Location.
Describe Transfer To FTP
Removes old custom objects that were created through the workflow framework.
Describe Workflow-CleanUp.
A RESTful API has one entry point, which is an individual resource. Each resource has its own unique URL, which must be communicated to the API clients so that they can find the API. It is common for the entry point to contain information on the API version, supported, features, and resource list. Each collection and resource in the API has its own URL. In Demandware, your public domain name for the resource URL is the DNS name mapped to the Demandware site (for example, www.example.com). In a sandbox, the Site ID identifies the actual site to use (for example, Demos-SiteGenesis-Site, SiteGenesis).
Describe how a URL in a RESTful call.
RESTful APIs obtain resources via URLs that make requests based on a limited set of methods (for example, GET, POST). The service determines the syntax and HTTP methods supported. For example, a read-only service might only support the support GET and POST requests. RESTful APIs use resources which are object instances that describe the available resource type(s), associated application data, behavior and relationships to other resources. Resources can be grouped into collections that contain a single type of resource.
Describe the RESTful API methodology.
encapsulate
Documents ______________ storefront-related data, such as product data or category data. You include them in the body of most API responses. POST, PUT, and PATCH methods typically require documents in the body of the API requests. JSON is the default format for documents, however, you can specify XML as the format.
name; verb
Each extension point has a unique ID, which contains the extension point _____________ and a _________: dw.ocapi.shop.Basket.addToBasket
GET; POST
It is based on individual HTTP methods (such as _________ or ____________), which REST can exploit to perform specific server-side actions.
For each request to this service, a session is created. Therefore, the number of requests should be fairly small. The actual number would depend on many factors including: storefront traffic, total number of customer sites, how the realm is provisioned, etc. The pipeline only accepts GET/POST requests. If you want to implement a full REST pattern, you must provide the REST operation to execute (for example, DELETE resource) as part of the URL. To make the pipeline callable, set it as public. To do this, have a URL to trigger the pipeline and use the HTTP parameters to pass information in and perform. Respond back via a template: <isprint value="${pdict.responseXml}" encoding="off"/> <isprint value="${pdict.responseJSON}" encoding="off"/>
List four considerations for using the previous approach.
An architecture, not a messaging format Better performance Scalable Standard, language independent URIs (less metadata; small and fast). Stateless Can use JSON
List six properties of REST.
Standard XML-based messaging format Uses packets bound via WSDL Extensive security standards Extensible Flexible (HTTP, or FTP/SMTP) Can be stateful
List six properties of SOAP.
200 (OK) 201 (Created) 204 (No Content) 400 (Bad Request) 401 (Unauthorized) 403 (Forbidden) 404 (Not Found) 405 (Method Not Allowed) 500 (Internal Server Error)
List the nine response status codes.
architecture
REST is an _____________, not a specific web service messaging format.
hooks.json
Register extension points statically by creating a package.json file, which you will place in the top level directory of a cartridge. In the file, set the hooks property to the path of a hooks.json configuration file. This path is relative to the directory containing the package.json file. The ______________ file contains an array with mappings from extension point names to script files. The path is relative to the directory where that file resides.
overhead; complexity
SOAP's performance ______________ and _______________ has resulted in the adoption of web services using JSON in conjunction with REST.
packets; functions
SOAP-based services don't deal directly with underlying XML messages; rather, they use XML ________________ and call ______________ previously defined in the service that they are calling. The client validates requests before sending. SOAP is known for its extensive standards for security.
NOT_STARTED
Scheduled jobs contain details, including: Planned Start time (and date), the job's current Status (___________________), and the Site ID.
Timeout - The amount of time a service stays alive before timing out due to inactivity. Use Locking - Whether or not a service should be locked, should it fail. Locked For - The amount of time the service has been locked. Maximum Attempts - The maximum number of retry attempts before a service is locked. Log Status - The log file status and level of data written to the log file.
The Integration Dashboard provides an at-a-glance status update of the services running on the platform. Details about each service include what five components?
GREEN - Service running smoothly. YELLOW - Attempts to makes calls to the service have been unsuccessful. RED - The Service is locked or not running.
The Integration Dashboard uses the following color-code scheme:
batch
The Integration Framework offers a flexible way to create and monitor jobs. You will use jobs to import or export data to and from the Demandware platform. You can configure and schedule jobs to run as ______________ processes in the future.
REST
The Open Commerce API facilitates real-time server-to-server communication, based on the ________________ paradigm.
Integration
The Service Configuration object provides the Service Framework with data regarding a specific service. This object generates the ______________ Dashboard found within Business Manager.
hierarchy
The Service Framework defines a ____________________ of classes. Simple JavaScript Inheritance is based on standard JavaScript prototypal and pseudo-classical inheritance methods. It uses any object's intrinsic prototype linkage and the new operator to build up the inheritance. Because this inheritance pattern somewhat mimics java inheritance, it should be familiar to most developers.
extend
The Simple JavaScript Inheritance library defines a single object called Class, which contains a single method called __________________.
locked
The Temporary object stores the statuses of all currently ______________ services.
access point
The URL specifies the ___________ _____________ to the Open Commerce API as well as the resource specific information needed to perform a given operation on a specific resource. Each URL consists of a base URL and an extended URL.
PCI compliant
The WebDAV client can use either an HTTP or HTTPS connection. When the WebDAV client uses an HTTPS connection, the connection becomes _______________ _____________. Therefore, WebDAV is safe to transfer files to both staging and production servers.
binary
The WebDAV protocol supports the transmission of both _____________ and compressed files (for example, WinZIP, GZIP). When transferring compressed files that contain a directory, it maintains the compressed directory structure.
View a service's URL View and/or update the URL's associated user credentials Change the service's behavior
The Webservice Credentials page enables you to do what three things?
Open Commerce API
The _________ ________________________ ___________ enables Demandware to integrate with storefront data used by other web applications and enterprise software to add functionality. Developers can leverage shopping widgets and experiences external to Demandware. For example, you can extend shopping experiences in the latest Facebook applications, create shoppable blogs through open plug-ins, incorporate mobile and tablet applications natively through community developed SDKs, and even include recommendation widgets inside point of sale applications.
base
The _____________ URL provides the main access point to the Open Commence API. It is the same for all API requests.
extended
The _________________ URL provides details to support a specific resource and a particular operation.
URLs
The client formats and sends requests in the form of _______________, which typically have parameters.
Hook Script
The hook's arguments and their return values are specific for each extension point. A single script file, called a _____________ _____________, can implement multiple related hook functions—each for a different hook.
server side
The request format and parameters must match the _____________ ________________ application specification so that the application can interpret it appropriately.
circuit breaker pattern
To ensure that timeouts occur, the Service Framework uses a __________ ___________ _____________ to manage the third party web services, ensuring that these web services are not inundated with requests after the service has already become unresponsive.
independently
To restrict permissions deeper in the links (for example, to restrict access to product image information), you must configure the client permissions for both resources, the products base resource /products/{id,} and the images sub resource /products/{id}/images, _____________________.
True
True or False: A verb may contain before or after as the pre-fix to indicate that they are pre- or post- processing hooks as appropriate.
True
True or False: Being stateless, REST provides improved performance. It does not store client context on the server between requests, therefore each request contains all the information necessary to handle that request. The client stores any all state data (for example, by using cookies).
True
True or False: JSON has less metadata and decorative tags, so that its packets are much smaller than XML. RESTful services can also return non-text values, such as binary files, images, PDF documents, and so on.
True
True or False: Jobs that have been started contain additional details such as the Start time, End time, Runtime (duration of the job run), and a hyperlink to the job's log file. To view details about a previously run job, expand the Workflow name.
True
True or False: RESTful requests are smaller and more concise because they contain less information or metadata than a SOAP request. REST is increasingly popular for mobile development where optimizing size and bandwidth is crucial.
True
True or False: Synchronous data transfers are also used to transfer data to, or from, the Demandware platform. With real-time services, the Demandware server invokes a service via a pipeline, SOAP, HTTP Client, or Open Commerce API and then waiting for a response to the request. Real-time services exchange data rather than files, thus they typically transfer much smaller amounts of information. As a result, they are less resource intensive than asynchronous data transfers. Demandware supports many types of URLs and can transfer various content items.
True
True or False: The Demandware platform can send data both synchronously and asynchronously.
True
True or False: The Integration Framework also uses Custom Object Definitions to implement a job.
True
True or False: The Open Commerce API gives you the flexibility to use another programming wrapper framework (e.g. PHP, iOS, Java) or mobile language such as Objective C or Java. You can also use JavaScript with AJAX calls and JQuery. Open Commerce API is built upon the web API foundation to provide caching, standard URL & data formats, and security. Each API contains its own document and a resource file.
True
True or False: The Service Framework manages the responsiveness between a Demandware eCommerce site and third party web services accessed on the platform. The Demandware platform contains multi-threaded application servers, which can spawn a limited number of threads. The Service Framework is designed to prevent a Demandware application from continuously making requests when the platform no longer has the requested service. It ensures that external requests made by Demandware contain a valid connection timeout. Use the Service Framework in conjunction with SOAP, REST, and other real time web services.
True
True or False: The base URL in production is different from the base URL in a sandbox.
True
True or False:For some data, it is some data can be delivered in near-real-time, and some can be batched.
Create a secured and public pipeline. Pass the inventory list ID, product ID, and the inventory number to be updated. Retrieve inventory list via inventory list ID. Get the record via product ID. Update the record. Respond back via template: <isprint value="UPDATE SUCCESS" encoding="off"/>
Use case: The client would like to update the inventory in Demandware as soon as the actual inventory changes due to selling something on amazon or other channel. List six approach steps.
Planned Start
Use the date filter under the ____________ ______________ column to see Jobs that ran on specific dates.
immediate
Using HTTP, the client sends a request and waits for a response from the HTTP server before performing other tasks. Upon receiving the request, the HTTP server provides an ______________ response (barring unforeseen circumstances).
Admin privileges
Using a third party WebDAV client application, administrators and developers can manage files (upload, download, move, rename, create, and delete) on the Demandware platform. To successfully transfer (move) files to the Demandware platform using a WebDAV client, you must have Business Manager ___________________ ____________________.
URL - Make a normal service call. SYSTEM UNAVAILABLE - Simulate a service unavailable status. DUMMY - Make the service act as a stub.
Using the Credentials type drop-down list, you can set the URL's behavior to which three values?
They are self-contained and self-describing, so other applications can use them. HTTP and XML provide the basis for Web services.
Web services provide a standard for applications to leverage real-time communication using HTTP. The two applications can be running on different operating systems, with different technologies, and programming languages because neither the client, nor the server needs to know the details about how the other one works. However, in order to communicate they must send requests and responses using: a standard format, a common set of verbs, and correct authentication (based on the API's specification). Clients can reside anywhere (for example, desktop, tablet, mobile device, Internet device). The following are two universal characteristics of web services:
How do integrations fit into the business processes? What are the use cases? What are the sending and receiving systems as well as their dependencies? What data needs to be transmitted? What are the characteristics of that data (such as: volume, frequency, change, and growth)? Is real-time necessary or can it be batched? Are there security considerations?
What are four questions to consider when planning for integration?
Enable Business Manager-type workflows Integrate content management Access backend business objects and data (currently limited to customers) Customer record search and update (Create, Read, Update, Delete (CRUD)) Pre-populate account with offsite data Integrate with ESP to create customer lists for email and marketing campaigns Integrate with the OMS Note: The Data API is not suitable for mass data.
What are seven use cases for the Data API?
Enable Business Manager-type workflows Integrate content management Access backend business objects and data (currently limited to customers) Customer record search and update (Create, Read, Update, Delete (CRUD)) Pre-populate account with offsite data Integrate with ESP to create customer lists for email and marketing campaigns Integrate with the OMS
What are seven use cases for the Shop API?
ERP / Order Management Payment Fraud check/authorization Customer Relationship Management (CRM) Personal Information Management (PIM) Rich Media
What are the six integration scenarios?
Workflow Schedules Workflow Components Workflow Plans The Integration Framework uses workflow schedules to define jobs to run. These jobs contain workflow components that specify the individual tasks for the job to perform. Workflow plans enable you to monitor the jobs using Business Manager. While you can customize a workflow, at its most basic level the Integration Framework associates a WorkflowCompoentDefinition with a WorkflowScheduleDefinition.
What are the three components which make up the Integration Framework?
Access storefront data Get up to date pricing and availability Pre-populate account profile with offsite data
What are the three uses for the Open Commerce API?
Create a checkout process Create an order process
What are two non uses for the Open Commerce API?
High use of system resources
What is the disadvantage of asynchronous data?
Job configuration Workflow components
What two parts does a workflow schedule have?
timestamp
When a file is written to the Demandware platform via any WebDAV connection, the WebDAV server resets the file's __________________ to the current date and time. This ________________rewrite also occurs when files are renamed, copied, modified or created via a WebDAV connection.
XML; JSON
While SOAP uses a standard format, RESTful services are flexible. The data returned can be in any format, but Demandware Web API supports ____________ and _____________.
SOAP; REST
While there are many web service standards, the most commonly used by Demandware developers are ___________ and _______________.
simultaneous
You use the Workflow Plan as dashboard to monitor the status of each job. You can also configure email notifications to provide alerts for any errors that occur during job execution. After a job completes, these results are available in the log file. The Integration Framework supports the processing of multiple ________________ jobs.
Hooks
__________________ provide a mechanism to make customizations to the Demandware platform. It is a single script function, which takes arguments and which may return a result. You use them in conjunction with extension points, which are well-defined locations in your business logic where you can plug in custom code.