/**
 * Shell Card Management APIsLib
 *
 * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ).
 */

import { boolean, object, optional, Schema, string } from '../schema.js';

export interface Role {
  /** Role Name of the user */
  roleName?: string;
  /** Whether the role is an administrator. */
  isCustomerAdmin?: boolean;
  /** Whether the role is a customer user. */
  isCustomerUser?: boolean;
  /** True if the role is Shell user, else false. */
  isShellAdmin?: boolean;
  /**
   * True/False.
   * True if the role is Service accounts, else false.
   */
  isServiceAccount?: boolean;
  /**
   * True/False.
   * True, if the role allows user administration, else false.
   */
  isUserAdmin?: boolean;
}

export const roleSchema: Schema<Role> = object({
  roleName: ['RoleName', optional(string())],
  isCustomerAdmin: ['IsCustomerAdmin', optional(boolean())],
  isCustomerUser: ['IsCustomerUser', optional(boolean())],
  isShellAdmin: ['IsShellAdmin', optional(boolean())],
  isServiceAccount: ['IsServiceAccount', optional(boolean())],
  isUserAdmin: ['IsUserAdmin', optional(boolean())],
});
