createFitTemporaryBleKey(params: CreateTemporaryBleKeyParams)

Requires:
@ray-js/lock-sdk≥1.2.0

Description

Create a temporary Bluetooth key on the accessory side

Parameters

ParameterTypeRequiredDescription
YesTemporary key params (name optional = unnamed key / effective)

Return Value

Type: Promise<unknown>
Cloud response

Error Code

Error CodeError Message
1032Missing validity time configuration
1033Missing start date
1034Missing expiry date
1010Start time is later than the expiry time
1035weeks not provided in weekly repeat mode
1042The device reported creation failure

Referenced Types

typeWeekWeekly repeat bitmap: indices 0–6 correspond to Sun–Sat; 0 inactive, 1 active
export type Week = [
  BitStatus,
  BitStatus,
  BitStatus,
  BitStatus,
  BitStatus,
  BitStatus,
  BitStatus,
];

Valid Values

EffectiveConfig.repeat
ValueDescriptionSince
none--
week--
Week
ValueDescriptionSince
0--
1--

Examples

import { createFitTemporaryBleKey } from '@ray-js/lock-sdk';
await createFitTemporaryBleKey({ name: 'Key1', effective });