door-control

module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 6, 2024 License: Apache-2.0

README

door-control

A door controller using aMember Pro and esprfid.

Setup

  1. Enable the "webhooks" and "Rest API Module" addons in aMember Pro
  2. Create a new user field in aMember Pro with the following (minimum) details:
    • Field Name: fob
    • Field Type: SQL
    • SQL field type: Text (string data)
    • Display Type: text
  3. Create a new "Remote API key" with the following permissions:
    • Users: index, get
    • Access: index, get
    • Products: index, get
    • Product Category: index, get
    • Product-Product Category: index, get
  4. Put all of your membership products under a common category in aMember Pro
  5. Create webhooks for accessAfterInsert, accessAfterDelete, accessAfterUpdate, userAfterInsert, userAfterUpdate, userAfterDelete to https://YOUR.DOOR/v1/amember
  6. Set up your MQTT server and esprfid board(s)

If aMember Pro has a user field named fob_access, door-control will make use of the following values:

  • subscription - door access is tied to aMember Pro access records
  • disabled - door access is disabled, regardless of aMember Pro records
  • enabled - door access is enabled, regardless of aMember Pro records

Installation

Set your environment variables of interest:

Then run ./controller.exe (or whatever the executable's name is). Downloads are available from the github releases.

Directories

Path Synopsis
api
cmd
compile_assets command
controller command

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL