# Filter location contacts Query location contacts using flexible filter criteria with AND/OR logic. By default, only non-deleted location contacts are returned (deletedAt: { isNull: true }). Override this by explicitly setting deletedAt filter criteria. Endpoint: POST /location-contacts/filter Version: 1.0.0 Security: BearerAuth ## Request fields (application/json): - `filter` (object) Filter criteria (optional - omit to return all location contacts). Note: deletedAt automatically defaults to { isNull: true } unless explicitly overridden. Example: {"and":[{"locationId":{"equalTo":"770e8400-e29b-41d4-a716-446655440000"}},{"isPrimary":{"equalTo":true}}]} - `filter.and` (array) All conditions must match (recursive) Example: [{"locationId":{"equalTo":"770e8400-e29b-41d4-a716-446655440000"}},{"isPrimary":{"equalTo":true}}] - `filter.or` (array) At least one condition must match (recursive) - `filter.not` (object) Negates the filter - `filter.id` (object) Filter options for ID fields (limited operations - exact match only) - `filter.id.equalTo` (string) Exact match - `filter.id.in` (array) Matches any UUID in the array - `filter.locationId` (object) Filter options for UUID fields (all operations) - `filter.locationId.notEqualTo` (string) Not equal to - `filter.locationId.notIn` (array) Does not match any UUID in the array - `filter.locationId.isNull` (boolean) Field is null (true) or not null (false) - `filter.customerContactId` (object) Filter options for UUID fields (all operations) - `filter.isPrimary` (object) Filter options for boolean fields - `filter.contactTypes` (object) Filter for contact type enum array field - `filter.contactTypes.includes` (string) Array contains this contact type Enum: "ACCOUNT_MANAGER", "BILLING", "DOCK_SHIPPING", "EMERGENCY", "LOCATION_MANAGER", "OWNER", "PROCUREMENT", "PURCHASING", "RATES_PRICING", "RECEIVING", "SHIPPING" - `filter.contactTypes.notIncludes` (string) Array does not contain this contact type Enum: "ACCOUNT_MANAGER", "BILLING", "DOCK_SHIPPING", "EMERGENCY", "LOCATION_MANAGER", "OWNER", "PROCUREMENT", "PURCHASING", "RATES_PRICING", "RECEIVING", "SHIPPING" - `filter.key` (object) Filter options for client key fields (limited operations - exact match only) - `filter.key.in` (array) Matches any value in the array - `filter.createdAt` (object) Filter options for datetime fields - `filter.createdAt.lessThan` (string) Before this datetime - `filter.createdAt.lessThanOrEqualTo` (string) On or before this datetime - `filter.createdAt.greaterThan` (string) After this datetime - `filter.createdAt.greaterThanOrEqualTo` (string) On or after this datetime - `filter.updatedAt` (object) Filter options for datetime fields - `filter.deletedAt` (object) Filter options for datetime fields - `pageSize` (integer) Number of results per page Example: 50 - `cursor` (string) Pagination cursor for next page ## Response 200 fields (application/json): - `data` (array, required) - `data.object` (string) Object type identifier Enum: "LOCATION_CONTACT" - `data.id` (string, required) Unique location contact identifier Example: "880e8400-e29b-41d4-a716-446655440000" - `data.locationId` (string, required) Location this contact is associated with Example: "770e8400-e29b-41d4-a716-446655440000" - `data.location` (object) The location this contact is associated with - `data.location.id` (string, required) Unique location identifier Example: "770e8400-e29b-41d4-a716-446655440000" - `data.location.customerId` (string, required) Customer (shipper profile) this location belongs to Example: "550e8400-e29b-41d4-a716-446655440000" - `data.location.customer` (object) The customer this location belongs to - `data.location.customer.id` (string, required) Unique customer identifier Example: "550e8400-e29b-41d4-a716-446655440000" - `data.location.customer.name` (string, required) Customer company name Example: "Acme Manufacturing Corp" - `data.location.customer.friendlyId` (string, required) Human-readable customer identifier, starts with "A" Example: "A123456" - `data.location.customer.status` (string, required) Customer account status (includes lead stages): - NEW: New lead, not yet contacted - CONTACTED: Initial contact made with lead - QUALIFIED: Lead has been qualified as potential customer - QUOTED: Quote has been provided to lead - NURTURING: Lead being nurtured for future opportunity - PENDING: Customer prospect pending activation - ACTIVE: Active customer account - INACTIVE: Deactivated customer account - BLOCKED: Customer account blocked from operations - CLOSED: Customer account permanently closed Enum: "NEW", "CONTACTED", "QUALIFIED", "QUOTED", "NURTURING", "PENDING", "ACTIVE", "INACTIVE", "BLOCKED", "CLOSED" - `data.location.customer.serviceTier` (any) Service tier level - `data.location.customer.website` (string,null) Customer website URL Example: "https://acme-manufacturing.com" - `data.location.customer.phoneNumber` (string,null) Primary phone number Example: "+1-555-123-4567" - `data.location.customer.industry` (any) Industry classification - `data.location.customer.annualRevenue` (any) Annual revenue range - `data.location.customer.annualSpend` (any) Annual freight spend estimate - `data.location.customer.spendType` (any) Customer spend type (contract vs spot pricing) - `data.location.customer.naics` (string,null) NAICS industry code Example: "336411" - `data.location.customer.ein` (string,null) Employer Identification Number Example: "12-3456789" - `data.location.customer.duns` (string,null) Dun & Bradstreet number Example: "123456789" - `data.location.customer.leadSource` (string,null) How this customer was acquired Example: "Referral" - `data.location.customer.dbaName` (string,null) Doing business as name Example: "Acme Corp DBA" - `data.location.customer.numberOfEmployees` (any) Company size by number of employees - `data.location.customer.externalId` (string,null) External system identifier Example: "EXT-12345" - `data.location.customer.currency` (any) Preferred currency for transactions - `data.location.customer.creditLimit` (number,null) Maximum credit allowed Example: 50000 - `data.location.customer.creditUsageWarning` (number,null) Credit usage warning threshold Example: 40000 - `data.location.customer.freeCreditReq` (number,null) Free credit requirement Example: 5000 - `data.location.customer.defaultMode` (any) Default transportation mode - `data.location.customer.defaultMargin` (number,null) Default margin percentage (0-1, e.g., 0.15 for 15%) Example: 0.15 - `data.location.customer.minMargin` (number,null) Minimum margin threshold Example: 0.1 - `data.location.customer.maxMargin` (number,null) Maximum margin threshold Example: 0.25 - `data.location.customer.defaultInternalNotes` (string,null) Default internal notes template Example: "Contact via email only" - `data.location.customer.defaultExternalNotes` (string,null) Default external notes template Example: "Please call 1 hour before delivery" - `data.location.customer.autoAcceptTender` (boolean,null) Auto-accept tender flag - `data.location.customer.group` (any) Customer group reference (minimal - id and key only) - `data.location.customer.paymentTerm` (any) Payment term configuration reference with full details - `data.location.customer.notes` (string,null) Internal notes about this customer Example: "Prefers email communication" - `data.location.customer.deactivationReason` (any) Reason for deactivation if status is INACTIVE - `data.location.customer.deactivationNotes` (string,null) Additional details about deactivation - `data.location.customer.deactivationDate` (string,null) When the customer was deactivated - `data.location.customer.closedAt` (string,null) When the customer account was closed - `data.location.customer.closedBy` (any) User who closed the account (full user details) - `data.location.customer.closedNotes` (string,null) Notes about account closure - `data.location.customer.corporateAddress` (any) Corporate headquarters address (nested location data) - `data.location.customer.billingAddress` (any) Billing address (nested location data) - `data.location.customer.qboCustomerId` (string,null) QuickBooks Online customer ID - `data.location.customer.key` (string,null) Client-defined reference identifier for this customer Example: "ERP-CUSTOMER-12345" - `data.location.customer.contacts` (array) Contacts for this customer - `data.location.customer.contacts.id` (string, required) Unique contact identifier Example: "550e8400-e29b-41d4-a716-446655440000" - `data.location.customer.contacts.key` (string,null) Client-defined reference identifier Example: "ERP-CONTACT-JOHN-001" - `data.location.customer.contacts.name` (string, required) Contact person's name Example: "John Smith" - `data.location.customer.contacts.contactInfo` (object, required) Contact information details (email, phone, title) - `data.location.customer.contacts.contactInfo.name` (string, required) Contact person's full name Example: "John Smith" - `data.location.customer.contacts.contactInfo.email` (string,null) Email address Example: "john.smith@example.com" - `data.location.customer.contacts.contactInfo.phoneNumber` (string,null) Phone number Example: "+1-555-0100" - `data.location.customer.contacts.contactInfo.title` (string,null) Job title or position Example: "Operations Manager" - `data.location.customer.contacts.phoneExtension` (string,null) Phone extension specific to this contact role Example: "1234" - `data.location.customer.contacts.isPrimary` (boolean, required) Whether this is the primary contact Example: true - `data.location.customer.contacts.contactTypes` (array,null) Types/roles this contact serves Enum: "ACCOUNT_MANAGER", "BILLING", "DOCK_SHIPPING", "EMERGENCY", "LOCATION_MANAGER", "OWNER", "PROCUREMENT", "PURCHASING", "RATES_PRICING", "RECEIVING", "SHIPPING" - `data.location.customer.contacts.notifications` (array,null) Shipment notification types Enum: "SHIPMENT_DELIVERED", "SHIPMENT_IN_TRANSIT", "SHIPMENT_LOADING", "SHIPMENT_OUT_FOR_DELIVERY", "SHIPMENT_PICKED_UP", "SHIPMENT_TENDER_REJECTED", "SHIPMENT_UNLOADING" - `data.location.customer.contacts.invitedUser` (any) User account invited/created for this contact - `data.location.customer.contacts.deletedBy` (any) User who deleted this contact - `data.location.customer.contacts.createdAt` (string, required) When the contact was created Example: "2025-01-15T10:00:00Z" - `data.location.customer.contacts.deletedAt` (string,null) When the contact was soft deleted - `data.location.customer.createdAt` (string, required) Timestamp when customer was created Example: "2025-01-15T10:00:00Z" - `data.location.customer.updatedAt` (string, required) Timestamp when customer was last updated Example: "2025-01-15T14:30:00Z" - `data.location.customer.deletedAt` (string,null) Timestamp when customer was soft-deleted (null if active) - `data.location.customer.deletedBy` (any) User who deleted the customer (full user details) - `data.location.name` (string, required) Location name Example: "ABC Warehouse - Dallas" - `data.location.key` (string,null) Client-defined reference identifier for this location Example: "ERP-LOC-DALLAS-01" - `data.location.type` (string) Type of location (SHIPPER, RECEIVER, or BOTH) Enum: "SHIPPER", "RECEIVER", "BOTH" - `data.location.isAppointmentRequired` (boolean, required) Whether appointments are required for this location Example: true - `data.location.notes` (string,null) External notes visible to carriers Example: "Call 24 hours ahead for appointment" - `data.location.internalNotes` (string,null) Internal notes (not visible to carriers) Example: "Use dock door 5 for expedited shipments" - `data.location.contacts` (array) Contacts for this location - `data.location.contacts.customerContactId` (string, required) Customer contact linked to this location Example: "660e8400-e29b-41d4-a716-446655440000" - `data.location.contacts.customerContact` (object) The customer contact details - `data.location.contacts.customerContact.customer` (object, required) Customer this contact belongs to (full customer details) - `data.location.contacts.customerContact.customer.id` (string, required) Customer UUID Example: "550e8400-e29b-41d4-a716-446655440000" - `data.location.contacts.customerContact.customer.key` (string,null) Client-defined reference ID if set Example: "ERP-CUSTOMER-ACME" - `data.location.contacts.customerContact.customer.friendlyId` (string, required) Human-readable customer identifier Example: "A123456" - `data.location.contacts.customerContact.customer.status` (string, required) Customer status Enum: "PROSPECT", "ACTIVE", "INACTIVE", "CHURNED" - `data.location.contacts.customerContact.customer.createdAt` (string, required) When the customer was created Example: "2025-01-15T10:00:00Z" - `data.location.contacts.customerContact.customer.updatedAt` (string, required) When the customer was last updated Example: "2025-01-15T14:30:00Z" - `data.location.contacts.customerContact.customer.deletedAt` (string,null) When the customer was soft deleted (null if active) - `data.location.contacts.customerContact.name` (string, required) Contact person's name (denormalized from ContactInfo for convenience) Example: "John Smith" - `data.location.contacts.customerContact.contactInfo` (object, required) Contact information details (email, phone, title) - nested from parent Contact record - `data.location.contacts.customerContact.isPrimary` (boolean, required) Whether this is the primary contact for the customer Example: true - `data.location.contacts.customerContact.notifications` (array,null) Shipment notification types to send to this contact Enum: "SHIPMENT_DELIVERED", "SHIPMENT_IN_TRANSIT", "SHIPMENT_LOADING", "SHIPMENT_OUT_FOR_DELIVERY", "SHIPMENT_PICKED_UP", "SHIPMENT_TENDER_REJECTED", "SHIPMENT_UNLOADING" - `data.location.contacts.customerContact.invitedUser` (any) User account invited/created for this contact (full user details) - `data.location.contacts.customerContact.deletedBy` (any) User who deleted this contact (full user details) - `data.location.contacts.customerContact.deletedAt` (string,null) When the contact was soft deleted (null if active) - `data.location.contacts.isPrimary` (boolean, required) Whether this is the primary contact for the location Example: true - `data.location.contacts.contactTypes` (array) Roles/types for this location contact Enum: "ACCOUNT_MANAGER", "BILLING", "DOCK_SHIPPING", "EMERGENCY", "LOCATION_MANAGER", "OWNER", "PROCUREMENT", "PURCHASING", "RATES_PRICING", "RECEIVING", "SHIPPING" - `data.location.contacts.key` (string,null) Client-defined reference identifier for this location contact Example: "ERP-LOC-CONTACT-001" - `data.location.contacts.createdAt` (string, required) Timestamp when location contact was created Example: "2025-01-15T10:00:00Z" - `data.location.contacts.updatedAt` (string, required) Timestamp when location contact was last updated Example: "2025-01-15T14:30:00Z" - `data.location.contacts.deletedAt` (string,null) Timestamp when location contact was soft-deleted (null if active) - `data.location.createdAt` (string, required) Timestamp when location was created Example: "2025-01-15T10:00:00Z" - `data.location.updatedAt` (string, required) Timestamp when location was last updated Example: "2025-01-15T14:30:00Z" - `data.location.deletedAt` (string,null) Timestamp when location was soft-deleted (null if active) - `pageInfo` (object, required) - `pageInfo.pageSize` (integer, required) Number of items per page Example: 50 - `pageInfo.hasNextPage` (boolean, required) Whether there are more pages Example: true - `pageInfo.hasPreviousPage` (boolean) Whether there are previous pages - `pageInfo.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 500 fields (application/json): - `error` (string, required) Error code - `message` (string, required) Human-readable error message