Get Lost Opportunity
Retrieve detailed information about a specific lost opportunity by its ID.
🔹 Endpoint Details
GET /api/v1/lost-opportunities/{id}
🔒 Authentication
| Header | Required | Description |
|---|---|---|
| Content-Type | Yes | Must be application/json |
| Authorization | Yes | Format: ONLIVESITE Credential:ONLIVEAccessKeyId, Signature=CalculatedSignature |
📝 Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
id | string (UUID) | Yes | Unique identifier of the lost opportunity |
🧩 Request Example
curl -X GET "https://openapi.onlive.site/api/v1/lost-opportunities/123e4567-e89b-12d3-a456-426614174000" \
-H "Content-Type: application/json" \
-H "Authorization: ONLIVESITE Credential:ONLIVEAccessKeyId, Signature=CalculatedSignature"
📥 Response Format (HTTP 200)
See Lost Opportunity Properties for the full entity schema.
| Field | Type | Description |
|---|---|---|
id | string (UUID) | Unique identifier |
organizationId | string (UUID) | Owning organization |
organizationName | string | Denormalized organization name |
entityType | enum | iCall | iChat | booking |
interactionId | string | Source interaction identifier |
status | enum | pending | processed | rejected |
reason | string | Loss reason |
comment | string | Free-form comment |
origin | string | Origin name |
userEmail | string | Contact email |
userPhone | string | Contact phone |
extraFields | object | Custom metadata |
userGroupId | string (UUID) | Assigned user group |
userGroup | string | Denormalized user group name |
involvedAgent | string (UUID) | Agent that handled the interaction |
visibleAt | string (ISO 8601) | Datetime the record becomes visible |
externalId | string | External identifier |
createdAt | string (ISO 8601) | Creation timestamp |
updatedAt | string (ISO 8601) | Last update timestamp |
Response Example
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"organizationId": "123e4567-e89b-12d3-a456-426614174001",
"organizationName": "Acme Inc.",
"entityType": "iCall",
"interactionId": "call_abc123",
"status": "processed",
"reason": "Customer chose a competitor",
"comment": "Customer asked to be contacted again in Q3",
"origin": "Website contact form",
"userPhone": "+33612345678",
"extraFields": { "department": "Sales" },
"userGroupId": "550e8400-e29b-41d4-a716-446655440000",
"userGroup": "Sales Team",
"involvedAgent": "123e4567-e89b-12d3-a456-426614174002",
"visibleAt": "2025-05-13T15:00:00Z",
"externalId": "frm_abc123",
"createdAt": "2025-05-13T15:00:00Z",
"updatedAt": "2025-05-13T16:42:11Z"
}
❌ Error Responses
| Status | Description |
|---|---|
| 404 | Lost opportunity not found |
This endpoint follows the standard error format.
📘 Notes
- The lost opportunity must belong to your organization
involvedAgent,organizationName,userGroup, andvisibleAtare server-managed
✅ Common Use Cases
- 🔍 Detail View: Open a single record in an agent dashboard
- 🔁 Sync: Refresh a local cache after a webhook
- 🧾 Audit: Fetch a record for compliance review