schema-aggregator

RetailContract Schema Pack v2.1

Overview

RetailContract is a Beckn v2.1 schema pack that declares buyer preferences, special instructions, and transaction terms at the contract (order) level. This schema was migrated directly from v2’s RetailCoreOrderAttributes with no structural changes, establishing buyer-side terms and preferences for fulfillment execution.

The schema enables buyers to specify:

Attachment Points

This schema attaches to the following Beckn v2.0 core entities via the contractAttributes container:

Schema Structure

Design Rationale

Field Semantics

buyerInstructions: Free-text field for any buyer-to-provider communication that doesn’t fit structured fields. Examples: “Please ring the doorbell twice,” “Avoid green bell peppers,” “Call before arriving.”

deliveryPreferences: Three distinct boolean flags provide granular control:

gift: Separates transactional purchase (invoicePreferences) from gift context:

invoicePreferences: Supports both B2C and B2B transactions:

loyalty: Enables rewards redemption at transaction time:

source: Supports marketing analytics and attribution modeling:

Non-Goals

This schema does not:

Upstream Candidates

Future enhancement opportunities for v2.2+:

  1. Communication Preferences: communicationChannel (sms, email, whatsapp) for delivery updates
  2. Sustainability Preferences: ecoPreferences: {minimalPackaging: boolean, sustainableMaterials: boolean}
  3. Insurance Election: insuranceOptIn: boolean, insuranceType: enum
  4. Subscription Metadata: isSubscription: boolean, subscriptionId: string, nextBillingDate: date-time
  5. Recurring Instructions: recurringInstructions: {frequency: string, startDate: date-time, endDate: date-time}
  6. Recipient Details: recipientName: string, recipientPhone: string for sender ≠ receiver
  7. Dietary/Allergy Info: dietaryRequirements: array, allergies: array (F&B specific but generalizable)
  8. Regional Tax Handling: reverseChargeApplicable: boolean, placeOfSupply: string
  9. Payment Terms: paymentTerms: {creditDays: number, dueDate: date} for B2B
  10. Notification Preferences: notificationSettings: {email: boolean, sms: boolean, push: boolean}