POST
https://api.nue.io/cpq/quotes/{targetQuoteId}:copyFromTemplate
Copies a template quote's line items, applied line price tags and price tiers onto an existing quote. This endpoint never creates a quote — the target must already exist and should be empty.
A template carries the SHAPE of a deal, never a locked price. After a real copy the result is ALWAYS repriced against the TARGET's own account, so a customer-dependent discount tier re-resolves to the target's band rather than the template's. A skipped copy changed nothing and is not repriced.
Copy or skip — always read skipped. When the target already RECORDS this same template as the one it was built from, a repeat call is a deliberate no-op: it returns 200 with skipped: true and lineItemsCopied: 0 rather than an error. That recording is what decides it, not the line items themselves, and only quotes created by POST /cpq/quotes:createFromTemplate carry it. A quote assembled any other way records no template, so a second copy onto it is refused with 409. Do not treat this endpoint as idempotent for a target you built yourself — read the target first.
Key behaviors:
- The template and target price books must match
- The template must have a price book
- Tax is recalculated for the TARGET's account and shipping jurisdiction after a real copy. This is best effort and is not reported back — read the quote back if the tax figure matters
- Header custom fields are not copied from the template; line-level custom fields are
Salesforce-integrated tenants only.
Apex equivalent: Ruby.GlobalQuoteService.copyQuoteFromTemplate(String templateQuoteId, String targetQuoteId). Note the Apex method does not enforce the template flag, while this endpoint does.
targetQuoteIdstringThe id of the existing quote to copy into.
acceptstringGenerated from available response content types
200<p>The copy completed, or was skipped because the target already records this template. Check <code>skipped</code>.</p>
400<p>Invalid request, the template has no price book, or the template and target price books differ.</p>
404The template or the target quote was not found.
409The target already has line items and does not record this template. Not retryable without clearing the target first.
500Internal server error.
curl --request POST \
--url https://api.nue.io/cpq/quotes/{targetQuoteId}:copyFromTemplate \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '{
"templateQuoteId": ""
}'