Skip to main content
Version: v1.0.0(int)

E040: List contacts linked to an entity

GET /api/contacts/linked-to

Returns the contacts linked to a given customer, vendor, or other entity, with their methods hydrated. Triggered from Customer Detail and Vendor Detail.

Authentication

Standard tenant route. Requires Authorization: Bearer <firebase-id-token> and X-Org-Id: <org-id>. Access: Member.

Request

Required query params: ?entityType= and ?entityId=, where entityType is "customer" or "vendor". No pagination — a single customer/vendor is expected to have a bounded number of contacts.

Response — 200 OK

{ "data": [ { "link": ContactEntityLink, "contact": Contact, "methods": [ ContactMethod ] } ] }

Errors

HTTPcodeCondition
404not_foundEntity does not exist.
422validation_failedMissing entityType or entityId.

Workflow

Calls W040 List contacts linked to an entity.