en-US/about_SPSearchMetadataCategory.help.txt

.NAME
    SPSearchMetadataCategory

# Description
    
    **Type:** Distributed
    **Requires CredSSP:** No
    
    This resource will deploy and configure a Metadata Category in a specified search
    service application.
    
    The default value for the Ensure parameter is Present. When not specifying this
    parameter, the Metadata Category is created.

.PARAMETER Name
    Key - String
    The name of the Metadata Category

.PARAMETER ServiceAppName
    Key - String
    The name of the search service app that this Metadata Category exists within

.PARAMETER AutoCreateNewManagedProperties
    Write - Boolean
    Specifies that when a new crawled property in this category is found, a corresponding managed property is created and mapped to this new crawled property

.PARAMETER DiscoverNewProperties
    Write - Boolean
    Specifies that if there are unknown properties in this category, these new properties are discovered during a crawl.

.PARAMETER MapToContents
    Write - Boolean
    Specifies that all crawled properties of type string are mapped to corresponding managed properties of this category.

.PARAMETER Ensure
    Write - string
    Allowed values: Present, Absent
    Present if the result source should exist, absent if it should not

.PARAMETER InstallAccount
    Write - String
    POWERSHELL 4 ONLY: The account to run this resource as, use PsDscRunAsCredential if using PowerShell 5

.EXAMPLE 1

This example shows how to create a new Search Metadata Category, using the required parameters

    Configuration Example
    {
        param(
            [Parameter(Mandatory = $true)]
            [PSCredential]
            $SetupAccount
        )
        Import-DscResource -ModuleName SharePointDsc

        node localhost {
            SPSearchMetadataCategory NewCategory
            {
                Name = "My New category"
                ServiceAppName = "Search Service Application"
                AutoCreateNewManagedProperties = $true
                DiscoverNewProperties = $true
                MapToContents = $true
                Ensure = "Present"
                PsDscRunAsCredential = $SetupAccount
            }
        }
    }