---
schema_version: "1"
id: 453b093d308bc1a806d9eaa2000f48cfbdc4d04c664faa35566293c75e1e067c
title: Create Order or Quote Invocable Action
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/ind/264-0-0/comms_invocable_action_create_order_or_quote.md
canonical_url: https://help.salesforce.com/s/articleView?id=ind.comms_invocable_action_create_order_or_quote.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 18a48330213fcea4c064f2a14dac583acbd9eb28e0d6adcd1fe67cdb49a9447c
description: Use this action to create either a quote or an order based on specified inputs. For example, a sales reps can use this action to create a quote or an order for a customer.
products:
  - Communications
  - Media
  - Energy and Utilities
release: "264"
---
# Create Order or Quote Invocable Action

Use this action to create either a quote or an order based on specified inputs. For example, a sales reps can use this action to create a quote or an order for a customer.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: Lightning Experience</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: <strong>Enterprise</strong>, <strong>Unlimited</strong>, and <strong>Developer</strong> Editions</td></tr></tbody></table>

## Industries CPQ API Used to Invoke Create Order or Quote Invocable Action

- createCart
- getPriceLists

## Input Values

| Parameter | description | data type |
| --- | --- | --- |
| objectType | The type of record that you want to create. Valid values are **Quote** and **Order**. | String |
| Name | The name of a quote that you want to create. | String |
| AccountId | The ID of the account record associated with the quote or order. | String |
| OpportunityId | The ID of the opportunity record associated with the quote. | String |

## Output Values

| Parameter | description | data type |
| --- | --- | --- |
| error | An error that was encountered during action execution. | String |
| Id | The record ID of the quote or order that's created. | String |
| Name | The name of a quote or order that's created. | String |
| messages | The messages returned from the CPQ API response. | List of String |
| priceList | The price list associated with the order or quote. | List of String |

## Example

JSON Request

```json
AccountId = (001DX000001osJOYAY)Name = (Test 123)objectType = (Quote)OpportunityId =  (006DX000001rygYYAQ)
```

JSON Response Body

```json
messages ([])Id (0Q0DX0000001mfU0AQ)error (null)Name (Test 123)priceList 
([{"messages":[],"actions":{"setpricelist":{"rest":{"params":{},"method":null,"link":null},
"remote":{"params":{"methodName":"updateCarts","inputFields":[{"devops001gs0__PriceListId__c":"a3sDX00000006ViYAI"}],
"cartId":"0Q0DX0000001mfU0AQ"}},"client":{"params":{}}}},"displaySequence":-1,"Id":"a3sDX00000006ViYAI","Name":"B2B Pricelist"}, 
{"messages":[],"actions":{"setpricelist":{"rest":{"params":{},"method":null,"link":null},
"remote":{"params":{"methodName":"updateCarts","inputFields":[{"devops001gs0__PriceListId__c":"a3sDX00000006VkYAI"}],
"cartId":"0Q0DX0000001mfU0AQ"}},"client":{"params":{}}}},"displaySequence":-1,"Id":"a3sDX00000006VkYAI","Name":"2020"}])
```