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

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

export interface CountryRestriction {
  /**
   * A list of ISO 3166-1 Numeric-3 country codes.
   * Example: 826 for United Kingdom.
   */
  countries?: string[];
  /**
   * Flag indicates whether the profile is inclusive or exclusive.
   * Example: False - (inclusive), i.e. the “Countries” property lists the countries where the transactions will be allowed.
   * True - (exclusive), i.e. the “Countries” property lists the countries where the transactions will be declined.
   */
  exclusive?: boolean;
}

export const countryRestrictionSchema: Schema<CountryRestriction> = object({
  countries: ['Countries', optional(array(string()))],
  exclusive: ['Exclusive', optional(boolean())],
});
