Sha256: c0b4080c399cc2a8cdfce591de292c778d4ccc265b572acf3bcd23631199345a

Contents?: true

Size: 1.23 KB

Versions: 2

Compression:

Stored size: 1.23 KB

Contents

# frozen_string_literal: true

module Seam
  module Clients
    class AcsEntrances < BaseClient
      def get(acs_entrance_id:)
        request_seam_object(
          :post,
          "/acs/entrances/get",
          Seam::AcsEntrance,
          "acs_entrance",
          body: {acs_entrance_id: acs_entrance_id}.compact
        )
      end

      def grant_access(acs_entrance_id:, acs_user_id:)
        request_seam(
          :post,
          "/acs/entrances/grant_access",
          body: {acs_entrance_id: acs_entrance_id, acs_user_id: acs_user_id}.compact
        )

        nil
      end

      def list(acs_credential_id: nil, acs_system_id: nil)
        request_seam_object(
          :post,
          "/acs/entrances/list",
          Seam::AcsEntrance,
          "acs_entrances",
          body: {acs_credential_id: acs_credential_id, acs_system_id: acs_system_id}.compact
        )
      end

      def list_credentials_with_access(acs_entrance_id:, include_if: nil)
        request_seam_object(
          :post,
          "/acs/entrances/list_credentials_with_access",
          Seam::AcsCredential,
          "acs_credentials",
          body: {acs_entrance_id: acs_entrance_id, include_if: include_if}.compact
        )
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
seam-2.0.0a2 lib/seam/clients/acs_entrances.rb
seam-2.0.0.prerelease.1 lib/seam/clients/acs_entrances.rb