Public/table/New-SNOWSCRequestedItem.ps1
function New-SNOWSCRequestedItem { <# .SYNOPSIS Creates a sc_req_item record in SNOW .DESCRIPTION Creates a record in the sc_req_item table .NOTES Uses New-SNOWObject as a template function. .OUTPUTS PSCustomObject. The full table record/s (-PassThru only). .LINK https://github.com/insomniacc/PSSnow/blob/main/docs/functions/New-SNOWSCRequestedItem.md .LINK https://docs.servicenow.com/csh?topicname=c_TableAPI.html&version=latest .EXAMPLE New-SNOWSCRequestedItem -Properties @{"<key>"="<value>"} -PassThru Creates a single record in sc_req_item and returns the new record with SysID #> [Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSShouldProcess', '')] [CmdletBinding(SupportsShouldProcess)] param ( [Parameter()] [boolean] $backordered, [Parameter()] [boolean] $billable, [Parameter()] [alias('item')] [string] $cat_item, [Parameter()] [string] $configuration_item, [Parameter()] [string] $context, [Parameter()] [string] $estimated_delivery, [Parameter()] [string] $flow_context, [Parameter()] [string] $order_guide, [Parameter()] [string] $price, [Parameter()] [string] $quantity, [Parameter()] [alias('recurring_price_frequency')] [string] $recurring_frequency, [Parameter()] [string] $recurring_price, [Parameter()] [string] $request, [Parameter()] [string] $requested_for, [Parameter()] [boolean] $active, [Parameter()] [string] $activity_due, [Parameter()] [string] $additional_assignee_list, [Parameter()] [string] $approval, [Parameter()] [string] $approval_set, [Parameter()] [string] $assigned_to, [Parameter()] [string] $assignment_group, [Parameter()] [alias('service')] [string] $business_service, [Parameter()] [string] $cmdb_ci, [Parameter()] [alias('additional_comments')] [string] $comments, [Parameter()] [string] $comments_and_work_notes, [Parameter()] [string] $company, [Parameter()] [string] $delivery_plan, [Parameter()] [string] $delivery_task, [Parameter()] [string] $description, [Parameter()] [string] $due_date, [Parameter()] [string] $expected_start, [Parameter()] [string] $follow_up, [Parameter()] [string] $group_list, [Parameter()] [string] $impact, [Parameter()] [boolean] $made_sla, [Parameter()] [string] $number, [Parameter()] [alias('opened')] [string] $opened_at, [Parameter()] [string] $opened_by, [Parameter()] [string] $parent, [Parameter()] [string] $priority, [Parameter()] [string] $service_offering, [Parameter()] [string] $short_description, [Parameter()] [string] $sla_due, [Parameter()] [string] $state, [Parameter()] [string] $urgency, [Parameter()] [string] $watch_list, [Parameter()] [alias('actual_end')] [string] $work_end, [Parameter()] [string] $work_notes, [Parameter()] [string] $work_notes_list, [Parameter()] [alias('actual_start')] [string] $work_start ) DynamicParam { Import-DefaultParamSet -TemplateFunction "New-SNOWObject" } Begin { $table = "sc_req_item" } Process { Invoke-SNOWTableCREATE -table $table -Parameters $PSBoundParameters } } |