UNPKG

card-management-sdk

Version:

The Shell Card Management API is REST-based and employs OAUTH 2.0,Basic and ApiKey authentication. The API endpoints accept JSON-encoded request bodies, return JSON-encoded responses and use standard HTTP response codes. All resources are located in the S

88 lines (84 loc) 2.69 kB
/** * Shell Card Management APIsLib * * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ). */ import { lazy, nullable, object, optional, Schema, string } from '../schema.js'; import { DayTimeRestrictions, dayTimeRestrictionsSchema, } from './dayTimeRestrictions.js'; import { LocationRestriction, locationRestrictionSchema, } from './locationRestriction.js'; import { ProductRestrictionCard, productRestrictionCardSchema, } from './productRestrictionCard.js'; import { UsageRestrictionsCard, usageRestrictionsCardSchema, } from './usageRestrictionsCard.js'; export interface BundleRestriction { /** * The value indicates what actions to be performed with respect to day time restriction. * Mandatory * Allowed values – * • Add: Apply the given restriction on the bundle. * • Default: No Day/Time restriction will be applied on the bundle in Gateway. */ dayTimeRestrictionAction?: string | null; /** * The value indicates what actions to be performed with respect to location restriction. * Mandatory * Allowed values – * • Add: Apply the given restriction on the bundle. * • Default: No location restriction will be applied on the bundle in Gateway. */ locationRestrictionAction?: string | null; /** * The value indicates what actions to be performed with respect to Product restriction. * Mandatory * Allowed values – * • Add: Apply the given restriction on the bundle. * • Default: No Product restriction will be applied on the bundle in Gateway. */ productRestrictionAction?: string | null; dayTimeRestrictions?: DayTimeRestrictions; productRestrictions?: ProductRestrictionCard; locationRestrictions?: LocationRestriction; usageRestrictions?: UsageRestrictionsCard; } export const bundleRestrictionSchema: Schema<BundleRestriction> = lazy(() => object({ dayTimeRestrictionAction: [ 'DayTimeRestrictionAction', optional(nullable(string())), ], locationRestrictionAction: [ 'LocationRestrictionAction', optional(nullable(string())), ], productRestrictionAction: [ 'ProductRestrictionAction', optional(nullable(string())), ], dayTimeRestrictions: [ 'DayTimeRestrictions', optional(dayTimeRestrictionsSchema), ], productRestrictions: [ 'ProductRestrictions', optional(productRestrictionCardSchema), ], locationRestrictions: [ 'LocationRestrictions', optional(locationRestrictionSchema), ], usageRestrictions: [ 'UsageRestrictions', optional(usageRestrictionsCardSchema), ], }) );