Managing Credentials

Learn how to manage credentials and assign them to users.

Credentials determine the means by which a user gains access at an entrance. Types of credentials include key cards, mobile passes, and PIN codes. This guide provide instructions on creating and removing credentials, and reassigning them to users.


Create a Credential for a User

To create a credential for a user, provide the user ID (acs_user_id) and the desired access method (access_method). Seam supports the following access methods:

  • code for a PIN code-based credential

  • card for a key card-based credential

  • mobile_key for a Seam mobile key.

Depending on the access control system and the type of credential you are issuing, you can also specify the following properties for the new credential:

  • PIN code (code).

  • Start and end time frame for the validity of the credential (starts_at and ends_at).

  • Whether the credential is a multi-phone sync credential. When creating a Seam mobile key, make sure to issue a multi-phone sync credential (is_multi_phone_sync_credential).

  • Brand-specific data.

Make sure to note any brand-specific metadata and restrictions. For details, see the applicable device or system integration guide.

The response includes the ID (acs_credential_id) of the newly-created credential, the user (acs_user_id) associated with the credential, and other additional properties of the credential.


Create a PIN Code-Based Credential

Request:

seam.acs.credentials.create(
  acs_user_id="33333333-3333-3333-3333-333333333333",
  access_method="code",
  code="824759"
)

Response:

AcsCredential(
  acs_credential_id='66666666-6666-6666-6666-666666666666',
  acs_user_id='33333333-3333-3333-3333-333333333333',
  code='824759',
  access_method='code',
  ...
)

Create a Key Card-Based Credential

Request:

seam.acs.credentials.create(
  acs_user_id="33333333-3333-3333-3333-333333333333",
  access_method="card",
  code="123456"
)

Response:

AcsCredential(
  acs_credential_id='77777777-7777-7777-7777-777777777777',
  acs_user_id='33333333-3333-3333-3333-333333333333',
  access_method='card',
  ...
)

Create a Seam Mobile Key

Depending on the ACS for which you want to create a credential, you may also need to include system-specific metadata. See the system integration guide for your ACS. For more information about mobile access and issuing mobile credentials, see Mobile Access and Issuing Mobile Credentials from an Access Control System.

Request:

This request contains manufacturer-specific metadata that may vary by manufacturer.

seam.acs.credentials.create(
  acs_user_id="33333333-3333-3333-3333-333333333333",
  allowed_acs_entrance_ids=[
    "55555555-5555-5555-5555-555555555555",
    "55555555-5555-5555-5555-000000000000"
  ],
  credential_manager_acs_system_id="88888888-8888-8888-8888-888888888888",
  access_method="mobile_key",
  is_multi_phone_sync_credential=True,
  starts_at="2024-03-01T10:40:00Z",
  ends_at="2024-03-04T10:40:00Z",
  ...
)

Response:

This response contains manufacturer-specific metadata that may vary by manufacturer.

AcsCredential(
  acs_credential_id='99999999-9999-9999-9999-999999999999',
  acs_user_id='33333333-3333-3333-3333-333333333333',
  access_method='mobile_key',
  is_multi_phone_sync_credential=True,
  ...
)

Delete a Credential

To delete a credential, provide the credential ID (acs_credential_id).

Request:

seam.acs.credentials.delete(
  acs_credential_id="66666666-6666-6666-6666-666666666666"
)

Response:

None

Last updated

Logo

© Seam Labs, Inc. All rights reserved.