Skip to main content

Schema

{
  "type": "object",
  "required": ["recommendation_id", "name", "student_id", "offers", "type"],
  "properties": {
    "recommendation_id": {
      "type": "string",
      "format": "uuid",
      "description": "Unique identifier for the recommendation"
    },
    "name": {
      "type": "string",
      "description": "Human-readable name for the recommendation set"
    },
    "student_id": {
      "type": "string",
      "format": "uuid",
      "description": "Unique identifier for the customer"
    },
    "offers": {
      "type": "array",
      "items": {
        "type": "string",
        "format": "uuid"
      },
      "description": "Array of offer UUIDs that are recommended for the customer"
    },
    "type": {
      "type": "string",
      "enum": ["SELF", "SEGMENT"],
      "description": "Type of recommendation - SELF for individual customer recommendations, SEGMENT for segment-based recommendations"
    }
  }
}

Field Descriptions

Required Fields

FieldTypeFormatDescription
recommendation_idstringUUIDUnique identifier for the recommendation
namestring-Human-readable name for the recommendation set
student_idstringUUIDUnique identifier for the customer
offersarray-Array of offer UUIDs that are recommended
typestringenumType of recommendation (SELF or SEGMENT)

Example

{
  "recommendation_id": "00000000-1234-5678-9abc-def012345678",
  "name": "Recommended For you",
  "student_id": "00000000-9779-438e-ae0d-b52099f6be51",
  "offers": [
    "00000000-aaca-4844-9cb0-54af8f897322",
    "00000001-c020-4d37-8d6e-4e4e30ff5671",
    "00000002-5fe2-466c-b58a-5ac8db631334"
  ],
  "type": "SELF"
}

Best Practices

  1. UUID Format: Ensure all offer IDs are valid UUID v4 format
  2. Data Validation: Validate that all offer IDs exist in your system before using them
  3. Caching: Consider caching recommendations to improve performance
  4. Error Handling: Handle cases where the offers array might be empty
Need help? Contact our support team at [email protected]