{"id":"ldhongen1990/firebase","name":"firebase","scope":"ldhongen1990","platform":"roblox","description":"Forked of original project https://github.com/raphtalia/FirebaseLuau to fix wally errors. My forked repo is over here: https://github.com/ldhongen1990/FirebaseLuau","version":"1.0.0","latest":"1.0.0","versions":["1.0.0"],"license":"MIT","licenseRating":"safe","licenseCaveats":[],"licenseVerified":true,"dependencies":{"evaera/promise":{"version":"^3.2.1","alias":"Promise"}},"integrity":"e1c9a351f17cc405e762cce815f631b07957bcaa2c7bc4c64774d54ec769074a","likes":0,"downloads":0,"install":"forest install ldhongen1990/firebase","url":"https://forest.dev/p/roblox/ldhongen1990/firebase","files":"https://api.forest.dev/ai/package/roblox/ldhongen1990/firebase/files","readme":"<h1 align=\"center\">\r\n  <br>\r\n  <img src=\"https://i.imgur.com/lmdjbmH.png\" width = \"230\" height = \"300\" alt=\"FirebaseLuau\">\r\n</h1>\r\n\r\n<p align=\"center\">\r\n    <a href=\"https://github.com/raphtalia/FirebaseLuau/issues\">\r\n    <img src=\"https://img.shields.io/github/issues-raw/raphtalia/FirebaseLuau\"\r\n         alt=\"FirebaseLuau Issue Tracking\">\r\n      <a href=\"https://github.com/raphtalia/FirebaseLuau/commits/main\">\r\n    <img src=\"https://img.shields.io/github/last-commit/raphtalia/FirebaseLuau\"\r\n         alt=\"FirebaseLuau Commits\">\r\n</p>\r\n  \r\n  \r\n\r\n# FirebaseLuau\r\n\r\nPromise based library for accessing Firebase services from within Roblox. Currently this project only has support for\r\nFirestore.\r\n\r\n## Setup\r\n\r\nAuthentication is done through Firebase's Authentication service using a normal email/password provider. This\r\n**is not** your actual email or password. Once an account is created update your rules to allow this account read/write\r\npermissions on any services you need.\r\n\r\nA simple example of a rule is allowing only the UID of the account to read and write.\r\n\r\n```cel\r\nrules_version = '2';\r\nservice cloud.firestore {\r\n  match /databases/{database}/documents {\r\n    match /{document=**} {\r\n      allow read, write: if request.auth != null && request.auth.uid == \"kaTY7zQKbkZsjvlkv2Hu6KQhRf02\";\r\n    }\r\n  }\r\n}\r\n```\r\n\r\n## Example\r\n\r\n```lua\r\nlocal Firebase = require(\"FirebaseLuau\")\r\nlocal firebase = Firebase.init({\r\n    ProjectId = \"PROJECT_ID\",\r\n    APIKey = \"WEB_API_KEY\",\r\n    Email = \"EMAIL\",\r\n    Password = \"PASSWORD\"\r\n})\r\n\r\nlocal usersCollection = firebase.Firestore:GetCollection(\"users\")\r\nlocal userDoc = usersCollection:GetDoc(\"72938051\") -- OR firebase.Firestore:GetDoc(\"users/72938051\")\r\n\r\nuserDoc:Write({\r\n    gold = 100,\r\n}):await()\r\n\r\nprint(userDoc:Read():expect())\r\n```\r\n","readmeTruncated":false}