ListCustomerProspectsRequest
| Field | Type |
|---|---|
customer_id | string |
Required scope: customer:read
POST /public-api/publicapi.v1.Customer/ListCustomerProspects
A customer gets a prospect each time it is approached as one: a create prospect
run, a website form, a Create Customer
with isProspect, or a known contact submitting again. Each prospect has its
own owner, source, opt-in and contact attempts, and several can be open at
once. A prospect stays open, with its latest contact attempt result as its
state, until the customer buys; then the one prospect credited with the sale
is won (wonAt). Prospects come newest first.
{ "customerId": "be85f4d1-b680-4964-bf62-9828fdf4ce04" }{ "prospects": [ { "id": "5b2e0c9a-6d1f-4a3b-8e7c-2f9a1b0c3d4e", "customerId": "be85f4d1-b680-4964-bf62-9828fdf4ce04", "status": "won", "origin": "public_api", "source": { "id": "a6d3c1f0-2b8e-4f7a-9c11-5e4d3b2a1f00", "name": "Website" }, "owner": { "memberId": "0f5c7a2e-3b1d-4e8f-9a6c-1d2e3f4a5b6c", "firstName": "Sam", "lastName": "de Vries" }, "optIn": { "agreed": true, "statement": "Yes, keep me posted about offers from Example Solar.", "termsUrl": "https://example.com/privacy", "answeredAt": "1794590000" }, "openedAt": "1794590000", "wonAt": "1794850000", "transactionId": "3c9a7e52-8a0d-4f1e-b6a2-7d5e9c0b4a11", "contactAttemptCount": 2, "lastContactAttempt": { "occurredAt": "1794600000", "channel": "phone", "outcome": "Appointment made", "outcomeKind": "positive" } } ]}A customer the API key may not read returns not_found (404). To follow
prospects across customers, use
List Prospects.
POST /public-api/publicapi.v1.Customer/ListCustomerProspects Lists a customer's prospects, newest first: one for each time the customer was approached as a prospect (a create prospect run, a website form, an API create), with its status, source, owner, opt-in and contact attempts. Several can be open at once; when the customer buys, one is won. Read-only.
| Field | Type |
|---|---|
customer_id | string |
| Field | Type | Description |
|---|---|---|
prospects | repeated Prospect | Newest first. |