SALEPRODREL: Related Product
The SALEPRODREL entity: A junction linking two products as related (cross-sell, upsell, complementary) with a reason explaining the relationship.
Default definition. This article describes the default
SALEPRODREL definition shipped with DemandFlow. Administrators can add, remove, rename, or re-type fields, change which ones are required, and alter the layout from the Definitions screen in Settings. Your tenant's current schema may differ from what is shown here. To read the current definition at any time, GET the DEFINITION object whose id matches SALEPRODREL.Entity properties
| Property | Value |
|---|---|
| Entity code | SALEPRODREL |
| Display name | Related Product |
| Plural | Related Products |
| Level | 30000 |
Use cases
Junction entity linking PROD to PROD with a directional relationship. Uses dual-comboKey: source product at position 1 (comboKey), related product at position 2 (comboKey2). On the PROD editor, 'Related Products' queries via comboKey to show outgoing relationships.
Fields
Related Product Link
| Field | Type | Required | Notes |
|---|---|---|---|
sourceProduct | reference → PROD | Yes | Source product |
relatedProduct | reference → PROD | Yes | Related product |
reason | text (multi-line) | Reason |
Relationships
- Lookups:
sourceProductpoints at aPRODrecord;relatedProductpoints at aPRODrecord.
Creating a Related Product via the API
POST /v1/objects
Authorization: Bearer <your-pat>
Content-Type: application/json
{
"entity": "SALEPRODREL",
"level": 30000,
"comboKey": "SUB:|ENT:",
"sourceProduct": "",
"relatedProduct": "",
"reason": "Example Reason"
}
Listing Related Products records
GET /v1/entities/SALEPRODREL/SUB