# Filter quotes Search for quotes using filter criteria. ## Common Filters - Active quotes: { "filter": { "status": { "in": ["DRAFT", "REQUESTED", "QUOTED"] } } } - Won quotes: { "filter": { "status": { "equalTo": "WON" } } } - By customer: { "filter": { "customerId": { "equalTo": "uuid" } } } - Expiring soon: { "filter": { "expiresAt": { "lessThanOrEqualTo": "2025-01-20T00:00:00Z" } } } Endpoint: POST /quotes/filter Version: 1.0.0 Security: BearerAuth ## Request fields (application/json): - `filter` (object) - `filter.id` (object) Filter options for UUID fields (all operations) - `filter.id.equalTo` (string) Exact match - `filter.id.notEqualTo` (string) Not equal to - `filter.id.in` (array) Matches any UUID in the array - `filter.id.notIn` (array) Does not match any UUID in the array - `filter.id.isNull` (boolean) Field is null (true) or not null (false) - `filter.status` (object) - `filter.status.equalTo` (string) Current status in the quote lifecycle. Initial states: - DRAFT: Quote being drafted - REQUESTED: Customer requested a quote (needs pricing) Active states: - QUOTED: Price sent to customer - RECEIVED_REPLY: Received reply from customer - SENT_REPLY: Sent reply to customer - RECEIVED_COUNTER: Received counter-offer - SENT_COUNTER: Sent counter-offer Final states: - WON: Customer accepted the quote - LOST: Quote not accepted - PASS: Broker declined to quote - CANCELED: Quote canceled Enum: "DRAFT", "REQUESTED", "QUOTED", "RECEIVED_REPLY", "SENT_REPLY", "RECEIVED_COUNTER", "SENT_COUNTER", "WON", "LOST", "PASS", "CANCELED" - `filter.status.notEqualTo` (string) Current status in the quote lifecycle. Initial states: - DRAFT: Quote being drafted - REQUESTED: Customer requested a quote (needs pricing) Active states: - QUOTED: Price sent to customer - RECEIVED_REPLY: Received reply from customer - SENT_REPLY: Sent reply to customer - RECEIVED_COUNTER: Received counter-offer - SENT_COUNTER: Sent counter-offer Final states: - WON: Customer accepted the quote - LOST: Quote not accepted - PASS: Broker declined to quote - CANCELED: Quote canceled Enum: "DRAFT", "REQUESTED", "QUOTED", "RECEIVED_REPLY", "SENT_REPLY", "RECEIVED_COUNTER", "SENT_COUNTER", "WON", "LOST", "PASS", "CANCELED" - `filter.status.in` (array) Enum: "DRAFT", "REQUESTED", "QUOTED", "RECEIVED_REPLY", "SENT_REPLY", "RECEIVED_COUNTER", "SENT_COUNTER", "WON", "LOST", "PASS", "CANCELED" - `filter.status.notIn` (array) Enum: "DRAFT", "REQUESTED", "QUOTED", "RECEIVED_REPLY", "SENT_REPLY", "RECEIVED_COUNTER", "SENT_COUNTER", "WON", "LOST", "PASS", "CANCELED" - `filter.side` (object) - `filter.side.equalTo` (string) Quote direction. - SELL: Selling to shipper (customer quote) - BUY: Buying from carrier (carrier quote) Enum: "SELL", "BUY" - `filter.side.notEqualTo` (string) Quote direction. - SELL: Selling to shipper (customer quote) - BUY: Buying from carrier (carrier quote) Enum: "SELL", "BUY" - `filter.customerId` (object) Filter options for UUID fields (all operations) - `filter.carrierId` (object) Filter options for UUID fields (all operations) - `filter.assigneeId` (object) Filter options for UUID fields (all operations) - `filter.amount` (object) Filter options for float/number fields - `filter.amount.lessThan` (number) Less than - `filter.amount.lessThanOrEqualTo` (number) Less than or equal to - `filter.amount.greaterThan` (number) Greater than - `filter.amount.greaterThanOrEqualTo` (number) Greater than or equal to - `filter.expiresAt` (object) Filter options for datetime fields - `filter.expiresAt.lessThan` (string) Before this datetime - `filter.expiresAt.lessThanOrEqualTo` (string) On or before this datetime - `filter.expiresAt.greaterThan` (string) After this datetime - `filter.expiresAt.greaterThanOrEqualTo` (string) On or after this datetime - `filter.createdAt` (object) Filter options for datetime fields - `filter.updatedAt` (object) Filter options for datetime fields - `filter.and` (array) - `filter.or` (array) - `filter.not` (object) - `pageSize` (integer) - `cursor` (string) ## Response 200 fields (application/json): - `data` (array, required) - `data.id` (string, required) Unique identifier Example: "550e8400-e29b-41d4-a716-446655440000" - `data.key` (string, required) Human-readable quote ID (e.g., "Q003602") Example: "Q003602" - `data.side` (string, required) Quote direction. - SELL: Selling to shipper (customer quote) - BUY: Buying from carrier (carrier quote) Enum: "SELL", "BUY" - `data.status` (string, required) Current status in the quote lifecycle. Initial states: - DRAFT: Quote being drafted - REQUESTED: Customer requested a quote (needs pricing) Active states: - QUOTED: Price sent to customer - RECEIVED_REPLY: Received reply from customer - SENT_REPLY: Sent reply to customer - RECEIVED_COUNTER: Received counter-offer - SENT_COUNTER: Sent counter-offer Final states: - WON: Customer accepted the quote - LOST: Quote not accepted - PASS: Broker declined to quote - CANCELED: Quote canceled Enum: "DRAFT", "REQUESTED", "QUOTED", "RECEIVED_REPLY", "SENT_REPLY", "RECEIVED_COUNTER", "SENT_COUNTER", "WON", "LOST", "PASS", "CANCELED" - `data.amount` (number,null) Quoted price Example: 2500 - `data.target` (number,null) Target price for margin calculation Example: 2200 - `data.margin` (number,null) Calculated margin percentage Example: 12 - `data.expiresAt` (string,null) Quote expiration timestamp - `data.customer` (object) Customer (for SELL quotes) - `data.customer.id` (string, required) Customer UUID Example: "550e8400-e29b-41d4-a716-446655440000" - `data.customer.key` (string,null) Client-defined reference ID if set Example: "ERP-CUSTOMER-ACME" - `data.customer.name` (string, required) Customer company name Example: "Acme Manufacturing Corp" - `data.customer.friendlyId` (string, required) Human-readable customer identifier Example: "A123456" - `data.customer.status` (string, required) Customer status Enum: "PROSPECT", "ACTIVE", "INACTIVE", "CHURNED" - `data.customer.phoneNumber` (string,null) Primary phone number Example: "+1-555-123-4567" - `data.customer.website` (string,null) Customer website URL Example: "https://acme-manufacturing.com" - `data.customer.createdAt` (string, required) When the customer was created Example: "2025-01-15T10:00:00Z" - `data.customer.updatedAt` (string, required) When the customer was last updated Example: "2025-01-15T14:30:00Z" - `data.customer.deletedAt` (string,null) When the customer was soft deleted (null if active) - `data.carrier` (object) Carrier (for BUY quotes) - `data.carrier.id` (string, required) Carrier UUID Example: "550e8400-e29b-41d4-a716-446655440000" - `data.carrier.name` (string, required) Carrier company name Example: "Swift Transportation" - `data.carrier.email` (string,null) Primary email address Example: "dispatch@swifttrans.com" - `data.carrier.createdAt` (string, required) When the carrier was created Example: "2025-01-15T10:00:00Z" - `data.carrier.updatedAt` (string, required) When the carrier was last updated Example: "2025-01-15T14:30:00Z" - `data.carrier.deletedAt` (string,null) When the carrier was soft deleted (null if active) - `data.order` (object) Order details (route, freight) - `data.order.id` (string) - `data.order.key` (string,null) - `data.order.mode` (string) Transportation mode. - TL: Full Truckload - LTL: Less than Truckload - AIR: Air freight - OCEAN: Ocean freight - RAIL: Rail freight - INTERMODAL: Intermodal (multiple modes) - DRAYAGE: Drayage/cartage Enum: "TL", "LTL", "AIR", "OCEAN", "RAIL", "INTERMODAL", "DRAYAGE" - `data.order.origin` (object) - `data.order.origin.city` (string) - `data.order.origin.stateProvince` (string) - `data.order.origin.postalCode` (string,null) - `data.order.destination` (object) - `data.order.pickUpDate` (string,null) - `data.order.deliveryDate` (string,null) - `data.order.equipment` (array) - `data.order.weight` (number,null) - `data.order.mileage` (number,null) - `data.lostReason` (any) Why the quote was lost - `data.lostReasonText` (string,null) Additional text for lost reason - `data.closedTime` (string,null) When the quote was closed (won/lost) - `data.assignee` (object) Assigned sales rep - `data.assignee.id` (string, required) User UUID Example: "550e8400-e29b-41d4-a716-446655440000" - `data.assignee.email` (string, required) User's email address Example: "john.doe@example.com" - `data.assignee.name` (string,null) User's full name Example: "John Doe" - `data.assignee.phone` (string,null) User's phone number Example: "+1-555-123-4567" - `data.assignee.phoneExt` (string,null) Phone extension Example: "123" - `data.assignee.status` (string, required) User account status Enum: "PENDING", "ACTIVE", "INACTIVE" - `data.assignee.avatarId` (string,null) Profile avatar document ID Example: "7c9e6679-7425-40de-944b-e07fc1f90ae7" - `data.assignee.createdAt` (string, required) When the user was created Example: "2025-01-15T10:00:00Z" - `data.assignee.updatedAt` (string, required) When the user was last updated Example: "2025-01-15T14:30:00Z" - `data.assignee.deletedAt` (string,null) When the user was soft deleted (null if active) - `data.shipmentId` (string,null) Shipment ID if converted - `data.shipmentKey` (string,null) Shipment friendly ID if converted - `data.createdAt` (string, required) - `data.updatedAt` (string,null) - `pagination` (object, required) - `pagination.pageSize` (integer, required) Number of items per page Example: 50 - `pagination.hasNextPage` (boolean, required) Whether there are more pages Example: true - `pagination.hasPreviousPage` (boolean) Whether there are previous pages - `pagination.endCursor` (string,null) Cursor for the next page (null if no next page) Example: "eyJpZCI6IjU1MGU4NDAwLWUyOWItNDFkNC1hNzE2LTQ0NjY1NTQ0MDAwMCJ9" ## Response 400 fields (application/json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message ## Response 401 fields (application/json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message ## Response 422 fields (application/json): - `error` (string, required) Error code Example: "validation_error" - `message` (string, required) Human-readable error message - `details` (array, required) Validation error details - `details.field` (string, required) Field name that failed validation - `details.message` (string, required) Validation error message