{
  "slug": "whatsapp-notifier",
  "name": "WhatsApp Order Notifier",
  "version": "1.2.0",
  "author": "POS Marketplace",
  "description": "Sends WhatsApp confirmation to customers after each sale.",
  "minAppVersion": "1.0.0",
  "hooks": ["sale.created", "sale.refunded"],
  "permissions": ["db.read", "http.outbound", "mail.send"],
  "http_allowlist": ["graph.facebook.com", "api.twilio.com"],
  "settings": {
    "provider":   { "type": "select", "options": ["meta","twilio"], "default": "meta", "label": "Provider" },
    "phone_id":   { "type": "string", "label": "Meta Phone Number ID", "default": "" },
    "api_token":  { "type": "password", "label": "API Token", "default": "" },
    "template":   { "type": "textarea", "label": "Message Template", "default": "Hi {name}, thank you for your purchase of {total}. Invoice: {invoice}." }
  },
  "menu": [
    { "label": "WhatsApp Logs", "url": "/plugins/whatsapp-notifier/logs", "icon": "bi-whatsapp" }
  ]
}