Spectrum Integration
  • Introduction
  • Ecommerce
    • Front End Integration
    • Load Design
    • Add to Cart
    • Save Design
    • Generate Cart Item
    • Pricing & Availability
    • Order Acknowledgement
    • Shipment Notification
    • Update Order Status
    • Order Search
    • Integration Driver
    • Production Related File Delivery
    • Spectrum + Shopify Integration
      • Overall Flow
      • Product Set Up: "Add-ons"
      • Line Item Properties
      • Shopify Cart
      • Order Processing
  • API
    • Environments
    • Image QueryString API
      • Image Transforms
      • Image Filters
      • Image Encoding
    • Rendering
    • WebToPrint (W2P)
    • Assets
    • Rate Limiting
  • Marketing
    • Share
  • General
    • Glossary
Powered by GitBook
On this page
  • Flow
  • Get Web to Print Status
  • W2P Queue

Was this helpful?

  1. API

WebToPrint (W2P)

Most customizations require web to print services that create output that can be sent to printers, embroiderers, lasermarking equipment, or other embellishment providers.

PreviousRenderingNextAssets

Last updated 7 months ago

Was this helpful?

The Spectrum allows Spectrum clients or manufacturing partners to retrieve output files that can be used to create unique designs. The files that are returned by Spectrum differ from product to product, but are commonly high-resolution graphics files that are sized to specific dimensions and quality guidelines that were established when on-boarding the product. Spectrum prioritizes web to print requests based on the incoming date and the priority that is set on the order acknowledgement.

Flow

The typical flow to create web to print files are as follows:

  • An end user customizes a product using Spectrum web or app-based tools.

  • The customization details are stored within Spectrum as a “RecipeSet” that contains one or more recipes.

  • The user adds the item to the E-Commerce cart and purchases.

  • Once the purchase is completed, the Spectrum client POSTs an call to Spectrum.

  • The will queue the item for creation of the print file. This process typically takes between 1-3 minutes depending on load.

  • The route can be used to check status and/or retrieve web to print files.

Get Web to Print Status

GET https://api.spectrumcustomizer.com/api/webtoprint/:readableId

It is assumed that once an order is acknowledged, the web to print process has begun creating the print files. As such, the Web to Print route can be considered as a status route to ensure that the files are ready. The route will start the web to print process if it has not been started previously, i.e. via order acknowledgement.

Path Parameters

Name
Type
Description

readableId*

string

8 digit alphanumeric RecipeSet readable identifier.

// Indicates a successful response with a client-specific JSON payload.  
// The 200 response is only used for clients that are not downloading files 
// and request a JSON-only payload.  This is uncommon. 
{
  "customPayload": {
    "exampleName": "exampleValue",
    "exampleNameEtc": "exampleValueEtc",
  }
}
// Indicates that the request has been accepted for processing, 
// but the processing has not been completed.
Web To Print for BJVYR44F is in the processing queue.
// Indicates that valid web to print files are ready, but instead of sending a potentially unwanted response body, it send the client the 
// URI of a response resource to the print files(s) using the Location header.

HTTP/1.1 303 See Other
Transfer-Encoding: chunked
Content-Type: text/plain; charset=utf-8
Location: https://cdn.spectrumcustomizer.com/assets/generated/recipeset/98RR5KP8/recipe/5FTHF782/enhanced/20210506202211059.png
Server: Kestrel
Access-Control-Allow-Origin: *
Request-Context: appId=cid-v1:3605eb3d-fbca-4b00-ab60-8ca886c5d8dc
Date: Fri, 07 May 2021 21:27:15 GMT


Web To Print for ZELQN9Y3 successfully created. Result in location.

// Indicates that the REST API can't map the client's URI 
// to a valid recipe that has been created.

Unable to locate an entity with matching ID.
// A server error with Spectrum has occurred.  All requests will be retried
// until that process can be completed.

Web To Print for BJVYR44F encountered an error and is in retry queue.

// Forbidden Indicates that the web to print request has been 
// received, but has been cancelled.

Web To Print for BJVYR44F was cancelled.

W2P Queue

Since backend operations are often complex and involve creating multiple high-quality outputs and specifications, it can take multiple seconds for each recipe processed to be completed in the queue. Spectrum will always favor providing adequate resources for user-facing operations which may result in delays for large orders containing many customized recipes or heavy traffic periods. In practice, orders are typically processed within minutes but can be up to one hour. To accommodate this, the web to print API exposes an endpoint that displays the status of the item in the queue and a result if it has been processed.

Spectrum uses web to print operations that translate the customization actions that a user performed on a recipe to high-quality output used in manufacturing. These operations are queued and processed in first in, first out based on the priority of the order in . This means that there is no strict guarantee that an order will be processed immediately based on the number of items in the queue and processing availability.

order acknowledgement
Order Acknowledgement API
Order Acknowledgement
Web To Print API
WebToPrint API