Repository navigation
platform sdk doors and access points
Access control uses four related entity types: Door, Area, Elevator, and AccessPoint. Door, Area, and Elevator inherit from AccessPointGroup. AccessPoint inherits from Entity and represents a monitored point used to enter or exit a secured area, such as a door side or elevator floor. The supported AccessPoint subclasses are Floor, FloorInput, and FloorOutput. A door side is represented by Door.DoorSide, accessed through Door.DoorSideIn and Door.DoorSideOut. Each Door.DoorSide groups the access points associated with that side of the door.
-
Door: a barrier with two sides, each side having its own readers, access rules, and state. -
Area: a logical region of the system that contains doors, elevators, cameras, and other entities and that drives antipassback, max-occupancy, and threat-level policy. -
Elevator: a vertical access path with aFloorCollectionand an optional cabin reader. -
AccessPoint: the per-side, per-device handle that links a logical access point (a card reader, a REX button, a door sensor) to the underlying hardware device.
A Door is a barrier with two sides (DoorSideIn, DoorSideOut). Each side has its own readers, its own access rules, and its own state in the system. The door's runtime state is exposed by IsLocked and IsOpen, and a set of configuration members controls timings, locking behavior, and schedule overrides.
Door door = engine.GetEntity<Door>(doorGuid);
Console.WriteLine($"{door.Name}: locked={door.IsLocked}, open={door.IsOpen}");
Console.WriteLine($"Type: {door.DoorType}");
Console.WriteLine($"Standard grant: {door.StandardGrantTimeInSeconds}s");A door's writable properties cover grant and entry timings (StandardGrantTimeInSeconds, ExtendedGrantTimeInSeconds, StandardEntryTimeInSeconds, ExtendedEntryTimeInSeconds, RelockDelayInSeconds), schedule-driven behavior flags (RelockOnClose, IgnoreAccessEventsWhenUnlockedBySchedule, IgnoreDoorOpenTooLongEventWhenUnlockedBySchedule), and AccessPermissionLevel. Read-only structured state includes DoorForced, DoorHeld, RequestToExit, TwoPersonRule, and AutoUnlockOverride. The UnlockSchedules and UnlockExceptionSchedules collections describe when the door is unlocked by schedule; Areas and Units describe membership and ownership.
Doors carry access rules per side. Use Door.FetchAccessRulesForSide(AccessRuleSide side) to enumerate rules:
ReadOnlyCollection<AccessRuleRecord> rulesIn =
door.FetchAccessRulesForSide(AccessRuleSide.In);
foreach (AccessRuleRecord rule in rulesIn)
{
Console.WriteLine($" Rule on IN side: {rule.Id}");
}To attach or detach rules:
-
AddAccessRule(Guid accessRuleGuid, AccessRuleSide side). -
RemoveAccessRule(Guid accessRule, AccessRuleSide side).
For the structure of an access rule and its members, see About access rules and schedules.
Override the door's normal unlock schedule for a specific window:
DateTime start = new DateTime(2025, 1, 15, 8, 0, 0, DateTimeKind.Utc);
DateTime end = new DateTime(2025, 1, 15, 18, 0, 0, DateTimeKind.Utc);
door.SetAutoUnlockOverride(unlock: true, utcStart: start, utcEnd: end);
// Later, clear the override.
door.RemoveAutoUnlockOverride();A door connects to its physical hardware through access points. Each access point is a typed handle (an AccessPointType) on a specific side.
Door.AddConnection(Guid device, AccessPointType type) adds a connection and returns the new access point's Guid. Door.UpdateConnection(Guid accessPoint, Guid device) rewires an existing connection. Door.RemoveConnection(Guid accessPointGuid) deletes the connection. Door.RemoveConnectionByDevice(Guid deviceGuid) removes any connection wired to a specific device. Door.GetConnections(AccessPointType) lists every existing connection of a given type. These connection methods accept the types DoorLock, PullStation, Rex, DoorSensor, Buzzer, and LockSensor.
Card readers are not added this way. Each door side exposes its reader read-only as DoorSideIn.Reader and DoorSideOut.Reader, and you wire a physical device to any access point with SetDevice(Guid).
Guid lockAp = door.AddConnection(lockDeviceGuid, AccessPointType.DoorLock);
Guid sensorAp = door.AddConnection(sensorDeviceGuid, AccessPointType.DoorSensor);For batch standardization across many doors, see Door templates.
Configure a preferred access control unit and interface module for a door:
-
SetPreferredUnit(Guid preferredUnitGuid)andRemovePreferredUnit()set or clear the unit preference. -
SetPreferredInterface(Guid preferredInterfaceGuid)andRemovePreferredInterface()set or clear the interface module preference. -
PreferredUnitandPreferredInterface(read-onlyGuid) report the current values.
The DoorLockDevice (read+write Guid) names the device that physically locks the door.
-
Door.SetIsLockedAndRaiseEvent(bool isLocked): publishes the lock or unlock state and corresponding event for a door owned by the SDK application. It does not operate the physical door. -
Door.SetIsOpenAndRaiseEvent(bool isOpen): publishes the open or close state and corresponding event for a door owned by the SDK application. It does not operate the physical door. -
Door.SetBuzzerState(bool active): drive the door's buzzer. -
Door.SetMaintenanceMode(bool active): toggle maintenance mode on the door. -
Door.AddEntityToAreaCaptiveDoor(Guid areaGuid): adds the door as a captive door of the given area.
For a door managed by Security Center, call engine.ActionManager.Open(doorGuid) or engine.ActionManager.UnlockDoor(doorGuid) to request the operation. Use these methods only to publish state and events for a door owned by the SDK application.
An Area is a logical region of the system. It contains doors, elevators, cameras, camera sequences, custom entities, and other entities. Areas drive policy: antipassback enforcement, max-occupancy enforcement, people counting, and per-area threat-level mappings.
Area area = engine.GetEntity<Area>(areaGuid);
Console.WriteLine($"{area.Name}: {area.AllDoors.Count} doors");
Console.WriteLine($"Antipassback: {area.AntipassbackMode}");
Console.WriteLine($"Active threat level: {area.ActiveThreatLevel}");
Console.WriteLine($"People in area: {area.PeopleCount.Count}");Read-only collections describe what the area contains:
An area exposes its members through read-only collections (AllDoors, PerimeterDoors, Cameras, CameraSequences, Elevators, plus other less-common entity types) and mutates them through paired Add*/Remove* methods (AddDoor/RemoveDoor, AddElevator/RemoveElevator, AddCamera/RemoveCamera, and so on). For perimeter behavior, SwitchPerimeterDoorSides(Guid door) flips a door's in/out side assignment and UnlockAllPerimeterDoors() unlocks every perimeter door at once. AccessControlSupport toggles whether access control enforcement is enabled for the area.
Antipassback prevents a credential from being used to enter the area twice without a corresponding exit. Set the area's AccessControlSupport property to true before setting AntipassbackMode.
-
AntipassbackMode(read+writeAntipassbackModeenum): the enforcement mode. Set this toSoftorHardbefore the other antipassback properties; while it isNone, settingAntipassbackSchedule,AntipassbackStrict, orAntipassbackTimeoutis rejected. -
AntipassbackSchedule(read+writeGuid): the schedule during which antipassback is enforced. -
AntipassbackStrict(read+writebool): whentrue, the system rejects credentials that violate antipassback. Whenfalse, violations are logged but access is granted. -
AntipassbackTimeout(read+writeint): how long, in minutes, an entry remains "open" before the system stops counting it for antipassback. Valid values are 0 through 120.
To clear an antipassback violation on a specific cardholder, Engine.ActionManager.ForgiveAntipassback(Guid entity) resets the entity's antipassback state.
Areas can enforce a maximum occupancy and track people count. To configure maximum occupancy, set AccessControlSupport to true, AntipassbackMode to Soft or Hard, and MaxOccupancyMode to Soft or Hard, in that order. Then set MaxOccupancyLimit to a whole number from 1 through 99,999.
-
MaxOccupancyMode(read+writeMaxOccupancyModeenum): how occupancy is enforced. -
MaxOccupancyLimit(read+writeint): the maximum number of people allowed in the area. -
PeopleCount(read-only): current cardholders detected in the area. -
ModifyPeopleCount(bool inAccess, Guid cardholder)andModifyPeopleCount(bool inAccess, IEnumerable<Guid> cardholders): programmatically add or remove cardholders from the area's people count. -
ResetPeopleCount(): clears the current count. -
GetPeopleCount(): returns the current list of cardholder Guids in the area.
List<Guid> peopleInArea = area.GetPeopleCount();
Console.WriteLine($"Currently {peopleInArea.Count} people in {area.Name}");Each area can carry per-threat-level configuration:
-
ActiveThreatLevel(read-onlyGuid): the threat level currently active on the area, if any. -
ThreatLevelMappings(read+writeList<AccessPointGroupThreatLevelMapping>): per-threat-level configuration that maps access point groups to specific behavior under each threat level.
For activating and deactivating threat levels, see About threat levels.
Area.CreateMap(MapCreationInfo creationInfo) creates a map associated with the area and returns the new Map entity. Area.DeleteMap() deletes the map. Area.MapId (read-only) reports the map's Guid.
For working with map objects on the resulting map (placing cameras, doors, areas, shapes, labels), see Maps.
Area.AccessPermissionLevel (int) reports the area's current permission level. Cardholders with a permission level lower than the area's required level are denied access regardless of access rules. The level is controlled by threat-level activation and deactivation, not set directly through this property.
An Elevator is a vertical access path. It owns a FloorCollection (Floors), a cabin reader, and access rules.
Elevator elevator = engine.GetEntity<Elevator>(elevatorGuid);
foreach (Guid floorGuid in elevator.Floors)
{
Floor floor = engine.GetEntity<Floor>(floorGuid);
Console.WriteLine($" Floor: {floor.Name}");
}
Guid cabinReader = elevator.RetrieveCabinReader();An elevator manages floors through AddFloor(Guid)/RemoveFloor(Guid), access rules through AddAccessRule(Guid)/RemoveAccessRule(Guid), and the cabin reader through SetCabinReader(Guid)/RetrieveCabinReader()/ClearCabinReader(). Floor is itself an entity; each floor can have associated FloorInput and FloorOutput devices for floor-level I/O.
For floor-specific schedule overrides, Engine.ActionManager.OverrideLockingScheduleOnFloor(...) is the action-manager equivalent of the per-door override.
An AccessPoint is a per-side, per-device handle. It is the SDK's representation of one logical reader, REX button, door sensor, door lock, buzzer, or other I/O point on a specific side of a door, area, or elevator. Doors create and manage access points indirectly through Door.AddConnection(...); the AccessPoint entity exposes the resulting handle and enables integrations to attach further behavior.
AccessPoint ap = engine.GetEntity<AccessPoint>(accessPointGuid);
Console.WriteLine($"{ap.AccessPointType} on {ap.AccessPointSide} side");
Console.WriteLine($"Door: {ap.Door}, Device: {ap.Device}");An access point's identity is its AccessPointType (the role it plays: CardReader, Rex, DoorSensor, DoorLock, Buzzer, and so on) and its AccessPointSide (which side of the door, area, or elevator it serves). AccessPointGroup reports the parent (door, area, elevator), Door reports the door when applicable, and Device reports the underlying physical device. SetDevice(Guid)/RemoveDevice() wire or unwire the device.
AddCardholder(Guid)/RemoveCardholder(Guid) and the matching group methods bind a cardholder or group directly to an access point, bypassing the access-rule mechanism. This is rarely the right approach for most integrations; prefer access rules.
For shunting an input access point (suppressing its alarms temporarily), Engine.ActionManager.ShuntAccessPointDevice(Guid accessPoint, bool shunt) toggles the shunt state. ShuntAccessPointGroupInputs(...) does the same across many access point groups at once.
- About access control: The access control hub.
- About cardholders and credentials: Cardholder and credential lifecycle in depth.
- About access rules and schedules: The policy that grants access at specific access points and door sides.
- About access control units and interface modules: The controllers that host doors and access points.
- Door templates: Reusable door configuration projected across many doors.
- Maps: Placing entities on operator maps.
- Overview
- Connecting to Security Center
- SDK certificates
- Referencing SDK assemblies
- ASP.NET hosting
- SDK compatibility
- Migrating to modern .NET
- Entities
- Entity cache
- Entity loading, cache, and query options
- Detecting entity changes
- Entity change event reference
- Transactions
- Security Center events
- Actions
- Security Desk
- Custom events
- Event-to-actions
- Managing macros
- ReportManager
- ReportManager query reference
- Access control raw events
- DownloadAllRelatedData and StrictResults
- Privileges
- Partitions
- Entity write restrictions
- About custom fields
- About video
- About cameras
- Enrolling a video unit
- Ingesting third-party video
- Archiver and auxiliary archiver roles
- Archive transfer
- About access control
- About cardholders and credentials
- About doors, areas, elevators, and access points
- About access rules and schedules
- About access control units and interface modules
- Enrolling an access control unit
- Door templates
- Visitors
- Mobile credentials
- About threat levels
- About alarms
- About incidents
- Maps
- Logging
- Overview
- Localization
- Certificates
- Lifecycle
- Threading
- State management
- Configuration
- Restricted configuration
- Events
- Queries
- Request manager
- Database
- Entity ownership
- Engine extensions
- Entity mappings
- Server management
- Custom privileges
- Custom entity types
- Resolving non-SDK assemblies
- Deploying plugins
- Modern .NET support
- Overview
- Localization
- Certificates
- Creating modules
- Tasks
- Pages
- Components
- Tile extensions
- Services
- Contextual actions
- Custom actions
- Options extensions
- Configuration pages
- Monitors
- Shared components
- Commands
- Extending events
- Map extensions
- Timeline providers
- Image extractors
- Credential encoders
- Credential readers
- Cardholder fields extractors
- Badge printers
- Content builders
- Dashboard widgets
- Incidents
- Logon providers
- Pinnable content builders
- Custom report pages
- Overview
- Getting started
- Media file formats
- MediaPlayer
- VideoSourceFilter
- MediaExporter
- MediaFile
- G64 converters
- FileCryptingManager
- PlaybackSequenceQuerier
- PlaybackStreamReader
- OverlayFactory
- PtzCoordinatesManager
- AudioTransmitter
- AudioRecorder
- AnalogMonitorController
- Camera blocking
- Overview
- Getting started
- Referencing entities
- Entity operations
- About access control in the Web SDK
- About video in the Web SDK
- Users and user groups
- Partitions
- Custom fields
- Custom card formats
- Actions
- Events and alarms
- Incidents
- Reports
- Tasks
- Macros
- Custom entity types
- System endpoints
- Performance guide
- Reference
- Endpoints
- Constants
- Enumerations
- Under the hood
- Troubleshooting