Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/subscription/azext_subscription/_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,14 @@
# --------------------------------------------------------------------------------------------

from azure.cli.core.commands.parameters import get_enum_type
from .subscription.models import OfferType


# pylint: disable=line-too-long
def load_arguments(self, _):
with self.argument_context('account create') as c:
c.argument('enrollment_account_name', options_list=('--enrollment-account-name', '--enrollment-account-object-id'), required=True, help='The name of the enrollment account which should be used to create a subscription.')
c.argument('offer_type', required=True, help='The offer type of the subscription. For example, MS-AZR-0017P (EnterpriseAgreement) and MS-AZR-0148P (EnterpriseAgreement devTest) are available.', arg_type=get_enum_type(['MS-AZR-0017P', 'MS-AZR-0148P']))
c.argument('offer_type', required=True, help='The offer type of the subscription. For example, MS-AZR-0017P (EnterpriseAgreement) and MS-AZR-0148P (EnterpriseAgreement devTest) are available.', arg_type=get_enum_type(OfferType))
c.argument('display_name', help='The display name of the subscription.')
c.argument('owner_object_id', help='The object id(s) of the owner(s) which should be granted access to the new subscription.')
c.argument('owner_spn', help='The service principal name(s) of the owner(s) which should be granted access to the new subscription.')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ class OfferType(str, Enum):

ms_azr_0017_p = "MS-AZR-0017P"
ms_azr_0148_p = "MS-AZR-0148P"
ms_azr_usgov_0017p = "MS-AZR-USGOV-0017P"
ms_azr_usgov_0015p = "MS-AZR-USGOV-0015P"
ms_azr_usgov_0148p = "MS-AZR-USGOV-0148P"


class SubscriptionState(str, Enum):
Expand Down