Public/Get-GCKnowledgeDocument.ps1
|
<# .SYNOPSIS Retrieves a single knowledge document by ID. .DESCRIPTION Returns the details of a specific document from a knowledge base in Genesys Cloud. Uses the GET /api/v2/knowledge/knowledgebases/{knowledgeBaseId}/documents/{documentId} endpoint. .PARAMETER KnowledgeBaseId The unique identifier of the knowledge base. .PARAMETER DocumentId The unique identifier of the document to retrieve. .EXAMPLE Get-GCKnowledgeDocument -KnowledgeBaseId 'kb-id' -DocumentId 'doc-id' .NOTES Genesys Cloud API: GET /api/v2/knowledge/knowledgebases/{knowledgeBaseId}/documents/{documentId} #> function Get-GCKnowledgeDocument { [CmdletBinding()] param( [Parameter(Mandatory = $true)] [string]$KnowledgeBaseId, [Parameter(Mandatory = $true)] [string]$DocumentId ) $endpoint = "knowledge/knowledgebases/$KnowledgeBaseId/documents/$DocumentId" return Invoke-GCApiRequest -Endpoint $endpoint -Method GET } |