{
  "name": "Apps Chats",
  "appDomain": "chat.app.privacysafe.io",
  "version": "0.7.4",
  "components": {

    "/index.html": {
      "startedBy": "user",
      "runtime": "web-gui",
      "capsRequested": {
        "apps": "opener",
        "logout": "all",
        "log": "all",
        "mailerid": true,
        "shell": {
          "fileDialog": "all",
          "userNotifications": true,
					"fsResource": {
						"otherApps": {
							"launcher.app.privacysafe.io": "ui-settings"
						}
					}
        },
        "storage": {
          "appFS": "default",
          "userFS": "all",
          "sysFS": "all"
        },
        "appRPC": [
          "AppChatsInternal", "ChatDeliveryService", "VideoGUIOpener"
        ],
        "otherAppsRPC": [
          {
            "app": "contacts.app.privacysafe.io",
            "service": "AppContacts"
          }
        ],
        "connectivity": "check"
      },
      "windowOpts": {
        "width": 1200,
        "height": 600,
        "minWidth": 800,
        "minHeight": 512,
        "maxWidth": 1440
      },
      "icon": "logo.png",
      "startCmds": {
        "open-chat-with": {
          "thisAppComponents": [ "/background-instance.js" ],
					"otherApps": "*"
				},
        "incoming-call": {
          "thisAppComponents": [ "/background-instance.js" ]
        }
      }
    },

    "/video-chat.html": {
      "services": {
        "VideoChatComponent": {
          "thisAppComponents": [ "/background-instance.js" ]
        }
      },
      "runtime": "web-gui",
      "capsRequested": {
        "appRPC": [
          "WebRTCSignalingCAP"
        ]
      },
      "forOneConnectionOnly": true,
      "windowOpts": {
      }
    },

    "/background-instance.js": {
      "services": {
        "AppChatsInternal": {
          "thisAppComponents": [ "/index.html" ]
        },
        "ChatDeliveryService": {
          "thisAppComponents": [ "/index.html" ]
        },
        "VideoGUIOpener": {
          "thisAppComponents": [ "/index.html" ]
        },
        "WebRTCSignalingCAP": {
          "thisAppComponents": [ "/video-chat.html" ]
        }
      },
      "runtime": "deno",
      "capsRequested": {
        "appRPC": [
          "AppChatsInternal", "ChatDeliveryService", "VideoChatComponent"
        ],
        "log": "all",
        "mailerid": true,
        "mail": {
          "sendingTo": "all",
          "receivingFrom": "all"
        },
        "shell": {
          "startAppCmds": {
            "thisApp": [ "incoming-call", "open-chat-with" ]
          }
        },
        "storage": {
          "appFS": "default",
          "userFS": "all",
          "sysFS": "all"
        }
      }
    }

  },
  "launchOnSystemStartup": [
    {
      "name": "Messaging background service",
      "component": "/background-instance.js",
      "icon": "logo.png",
      "description": "Starts backround process to observe messaging and show notifications when new messages arrive"
    }
  ]
}
