BoldSales

API Documentation

Sales Documents

Sales documents represent the key paperwork used throughout the sales cycle, such as quotes, contracts, and invoices. These documents capture essential details, such as terms, pricing, and commitments, ensuring both your team and clients stay aligned at every stage of the deal.

Create a sales document

post/api/v1/sales-documents

Creates a new sales document and returns the created document details upon a successful API call.

Code snippet

curl -X 'POST' \
 'https://{yourdomain}/api/v1/sales-documents?skipValidation=false' \
 -H 'accept: text/plain; x-api-version=1.0' \
 -H 'x-api-key: {your API key}' \
 -H 'Content-Type: application/json-patch+json; x-api-version=1.0' \
 -d '{
   "data": {
     "documentTypeId": 1,
     "template": {
       "id": 10
     },
     "name": "Enterprise Proposal - TechCorp",
     "pipelineRecord": {
       "id": 202730
     },
     "company": {
       "id": 1081
     },
     "primaryContact": {
       "id": 1
     },
     "totalValue": 5000,
     "expirationDate": "2026-04-30",
     "reason": "Contract renewal opportunity",
     "isPrimary": true,
     "notes": "Follow up with decision maker",
     "owner": {
       "id": 100
     },
     "status": {
       "id": 1
     },
     "termsAndConditions": "Payment due within 30 days",
     "billingStreet": "123 Main Street",
     "billingCity": "New York",
     "billingState": "New York",
     "billingCountry": "US",
     "billingPostalCode": "1252",
     "shippingStreet": "123 Main Street",
     "shippingCity": "New York",
     "shippingState": "New York",
     "shippingCountry": "US",
     "shippingPostalCode": "1252",
     "customFields": {
      "cf_purchase_order_number": 1001
     }
   }
 }'

Query parameters

skipValidationbooleanA flag indicating whether to bypass validation checks during sales document creation. If set to true, the system skips checks for required fields, conditional logic, and field dependencies. When false (or unspecified), all standard validations are applied.

Request body

FieldDescriptionExampleValidation
documentTypeIdshortRequiredThe unique identifier of the sales document type."documentTypeId": 1Accepts a valid document type ID.

templateobjectRequired

Template that structures the sales document.

idintegerRequiredThe ID of the template used to format the document. Retrieve the ID using the Get all published templates API.

"template": { "id": 10 }

Accepts a valid template ID.

namestringRequiredName or title of the sales document."name": "Enterprise Proposal - TechCorp"Maximum 255 characters.

pipelineRecordobject

Pipeline record associated with this sales document.

idintegerRequiredThe ID of the pipeline record that will be associated with this sales document. This ID can be retrieved by calling the Get all pipeline records API.

"pipelineRecord": { "id": 202730 }

Accepts a valid pipeline record ID.

companyobject

Company associated with this sales document.

idintegerRequiredThe ID of the company that will be associated with this sales document. This ID can be retrieved by calling the Get all companies API.

"company": { "id": 1081 }

Accepts a valid company ID.

primaryContactobject

Primary contact person for this sales document.

idintegerRequiredThe ID of the contact that will be associated with this sales document. This ID can be retrieved by calling the Get all contacts API.

"primaryContact": { "id": 1 }

Accepts a valid contact's ID.

totalValuedecimalTotal monetary value of the sales document."totalValue": 5000
expirationDatestringExpiration date when the document is no longer valid."expirationDate": "2026-04-30"Format: YYYY-MM-DD (ISO 8601)
reasonstringReason for creating or updating the sales document."reason": "Contract renewal opportunity"
isPrimarybooleanIndicates whether the sales document is the primary document associated with the pipeline record."isPrimary": trueAccepts boolean values: true or false. Supported only for Quotes.
notesstringInternal notes or comments related to the sales document."notes": "Follow up with decision maker"

ownerobject

User responsible for managing this sales document.

idintegerRequiredThe ID of the user who will be the owner of this sales document. This ID can be retrieved by calling the Get all users API.

"owner": { "id": 100 }

Accepts a valid user's ID.

statusobjectRequired

Current workflow status of the sales document.

idintegerRequiredStatus option ID (e.g., draft, sent to customer, accepted).

"status": { "id": 1 }

Accepts a valid status ID.

termsAndConditionsstringLegal terms and conditions applicable to this sales document."termsAndConditions": "Payment due within 30 days"Maximum 5000 characters.
billingStreetstringStreet address for billing purposes."billingStreet": "123 Main Street"Maximum 255 characters.
billingCitystringCity name in the billing address."billingCity": "New York"Maximum 255 characters.
billingStatestringState or region in the billing address."billingState": "New York"Maximum 255 characters.
billingCountrystringCountry name in the billing address."billingCountry": "US"Maximum 255 characters.
billingPostalCodestringPostal or ZIP code for the billing address."billingPostalCode": "1252"Maximum 255 characters.
shippingStreetstringStreet address for shipping purposes."shippingStreet": "123 Main Street"Maximum 255 characters.
shippingCitystringCity name in the shipping address."shippingCity": "New York"Maximum 255 characters.
shippingStatestringState or region in the shipping address."shippingState": "New York"Maximum 255 characters.
shippingCountrystringCountry name in the shipping address."shippingCountry": "US"Maximum 255 characters.
shippingPostalCodestringPostal or ZIP code for the shipping address."shippingPostalCode": "1252"Maximum 255 characters.
customFieldsobjectUser-defined custom fields to extend the sales document with additional information. Refer to the Field types page to learn more about field types and their request formats."cf_discount": 10

Example response

201 Created

{
  "message": "Document saved successfully.",
  "data": {
     "id": "doc-123",
     "publicDocumentId": "3a6d2234-6564-437b-aded-94a2fb56e0dc",
     "documentUrl": "https://{yourdomain}.boldsalescrm.com/sales-document/review/4f7c2122-5720-41e4-94b6-7e00098f1236"
  }
}