New-SCSpfTenant

Creates a new tenant for a hoster.

Syntax

New-SCSpfTenant [-AccountStatus <String>] -Certificate <String> [-Confirm] -IssuerName <String> -Name <String>
 [-Stamps <Stamp[]>] [-SubscriptionId <Guid>] [-WhatIf] [<CommonParameters>]
New-SCSpfTenant [-AccountStatus <String>] [-Confirm] -IssuerName <String> -Key <String> -Name <String>
 [-Stamps <Stamp[]>] [-SubscriptionId <Guid>] [-WhatIf] [<CommonParameters>]

Description

The New-SCSPFTenant cmdlet creates a new tenant in Service Provider Foundation. If you are a service provider, the tenants are your paying customers. If you are using Service Provider Foundation in a private cloud, the tenants are the business units in your organization.

Examples

Example 1: Create a new tenant

PS C:\>$Path = "C:\Temp\ADatum29D.cer"
PS C:\> $Certificate = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2($Path)
PS C:\> $Key = [Convert]::ToBase64String($Certificate.RawData)
PS C:\> $SubscriptionId = [System.Guid]::NewGuid().ToString()
PS C:\> New-SCSPFTenant -IssuerName "Contoso" -Key $Key -Name "ADatum" -SubscriptionID $SubscriptionId

The first two commands create the $Certificate variable to contain the issued certificate for the tenant.

The third command creates the $Key variable to contain the public key for the certificate.

The fourth command creates the $SubscriptionId variable to contain the GUID for the subscription.

The fifth command creates the tenant with the name of the trusted issuer of the certificate, the public key, a specified name, and the GUID associated with the subscription.

Parameters

-AccountStatus

Specifies the status of a tenant. Specify 0 for Active, or 1 for Suspended.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Certificate

Specifies the path to the certificate file for the tenant.

Type:String
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False
-IssuerName

Specifies the name of the party that issued the certificate for the tenant. This parameter is metadata to verify a token submitted by the tenant; do not confuse this parameter with a trusted issuer object.

Type:String
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Key

Specifies the public key that validates a signed token submitted by a tenant in claims-based authentication.

Type:String
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Name

Specifies the name to give to the tenant.

Type:String
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Stamps

Specifies the name of one or more stamp objects to associate with the new tenant. To obtain a stamp, use the Get-SCSPFStamp cmdlet.

Type:Stamp[]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-SubscriptionId

Specifies the GUID for a subscription of a tenant. This value cannot be changed after the tenant is created.

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Required:False
Position:Named
Default value:False
Accept pipeline input:False
Accept wildcard characters:False