mirror of
https://github.com/snazy2000/SnipeitPS.git
synced 2025-12-13 18:02:30 +00:00
Merge pull request #109 from snazy2000/develop
Fixed missed aliases on parameter rename. Updated docs.
This commit is contained in:
commit
c5e02c8cfb
78 changed files with 7008 additions and 1629 deletions
22
CHANGELOG.md
22
CHANGELOG.md
|
|
@ -5,4 +5,24 @@ All notable changes to this project will be documented in this file.
|
|||
The format is based on [Keep a Changelog](http://keepachangelog.com/),
|
||||
and this project adheres to [Semantic Versioning](http://semver.org/).
|
||||
|
||||
## [1.0] - 2017-11-18
|
||||
# [v1.1.x] - 2021-05-18
|
||||
|
||||
## Pull request rollup release. Lots of new features including:
|
||||
|
||||
### New features
|
||||
- Powershell 7 compatibility. So you can use SnipeItPS on macos or linux .
|
||||
- Get every asset, model, licence with snipeit id by using -id parameter
|
||||
- Get assets also by -asset_tag -or serialnumber
|
||||
- Get functions also return all results from snipe when using -all parameter (by @PetriAsi)
|
||||
|
||||
### New functions
|
||||
- Reset-AssetOwner by @lunchboxrts
|
||||
- Remove-Asset by @sheppyh
|
||||
- Added Remove-AssetMaintenance by @sheppyh
|
||||
- Remove-User @gvoynov
|
||||
|
||||
### Fixes
|
||||
- Fixed version number on powershell gallery
|
||||
- Fixed Set-AssetOwner when checking asset out to an other asset.
|
||||
|
||||
## [v1.0] - 2017-11-18
|
||||
|
|
|
|||
|
|
@ -32,3 +32,6 @@ Get-Help about_SnipeitPS
|
|||
Get-Command -Module SnipeitPS
|
||||
Get-Help Get-Asset -Full # or any other command
|
||||
```
|
||||
### Reporting bugs and issues
|
||||
Please use -Verbose switch with command you have problem with.
|
||||
Then create ticket here with all -Verbose output
|
||||
|
|
|
|||
|
|
@ -1,6 +1,9 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Accessories
|
||||
Gets a list of Snipe-it Accessories
|
||||
|
||||
.DESCRIPTION
|
||||
Gets a list of Snipe-it Accessories
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Accessory data
|
||||
|
|
@ -12,7 +15,7 @@ A id of specific Accessory
|
|||
Specify the number of results you wish to return. Defaults to 50. Defines batch size for -all
|
||||
|
||||
.PARAMETER offset
|
||||
Offset to use
|
||||
Result offset to use
|
||||
|
||||
.PARAMETER all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
|
@ -24,12 +27,13 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Accessory -url "https://assets.example.com" -token "token..."
|
||||
Get-Accessory -search Keyboard
|
||||
|
||||
.EXAMPLE
|
||||
Get-Accessory -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "HP" }
|
||||
Get-Accessory -id 1
|
||||
|
||||
#>
|
||||
|
||||
function Get-Accessory() {
|
||||
Param(
|
||||
[string]$search,
|
||||
|
|
|
|||
|
|
@ -1,18 +1,18 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Gets a list of Snipe-it Assets
|
||||
Gets a list of Snipe-it Assets or specific asset
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the assets data
|
||||
|
||||
.PARAMETER id
|
||||
A text string to search the assets data
|
||||
ID number of excact snipeit asset
|
||||
|
||||
.PARAMETER asset_tag
|
||||
Specify exact asset tag to query
|
||||
Exact asset tag to query
|
||||
|
||||
.PARAMETER asset_serial
|
||||
Specify exact asset serial to query
|
||||
Exact asset serialnumber to query
|
||||
|
||||
.PARAMETER order_number
|
||||
Optionally restrict asset results to this order number
|
||||
|
|
@ -71,6 +71,7 @@ Get-Asset -search "myMachine"-url "https://assets.example.com"-token "token..."
|
|||
.EXAMPLE
|
||||
Get-Asset -asset_tag "myAssetTag"-url "https://assets.example.com"-token "token..."
|
||||
#>
|
||||
|
||||
function Get-Asset() {
|
||||
Param(
|
||||
[string]$search,
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Gets a list of Snipe-it Assets
|
||||
Lists Snipe-it Assets Maintenances
|
||||
|
||||
.PARAMETER asset_id
|
||||
|
||||
Asset ID of the asset you'd like to return maintenances for
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the assets data
|
||||
Search string
|
||||
|
||||
.PARAMETER sort
|
||||
Specify the column name you wish to sort by
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Categories
|
||||
Gets a list of Snipe-it Categories
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Categories data
|
||||
|
|
@ -18,16 +18,16 @@ Offset to use
|
|||
A return all results, works with -offset and other parameters
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
Url of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Category -url "https://assets.example.com" -token "token..."
|
||||
Get-Category -id 1
|
||||
|
||||
.EXAMPLE
|
||||
Get-Category -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Laptop" }
|
||||
Get-Category -search "Laptop"
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Companies
|
||||
Gets a list of Snipe-it Companies
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Companies data
|
||||
|
|
@ -16,7 +16,6 @@ Offset to use
|
|||
|
||||
.PARAMETER all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
|
|
@ -24,10 +23,12 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Company -url "https://assets.example.com" -token "token..."
|
||||
Get-Company
|
||||
Gets all companies
|
||||
|
||||
.EXAMPLE
|
||||
Get-Company -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Company1" }
|
||||
Get-Company -id 1
|
||||
Gets specific company
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Components
|
||||
Gets a list of Snipe-it Components
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Components data
|
||||
|
|
@ -18,16 +18,22 @@ Offset to use
|
|||
A return all results, works with -offset and other parameters
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
URL of Snipeit system,can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Component -url "https://assets.example.com" -token "token..."
|
||||
Get-Component
|
||||
Returns all components
|
||||
|
||||
.EXAMPLE
|
||||
Get-Component -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Memory" }
|
||||
Get-Component -search display
|
||||
Returns search results containeing string display
|
||||
|
||||
.EXAMPLE
|
||||
Get-Component -id
|
||||
Returns specific component
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,15 +1,15 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Returns a list of all Snipe-IT custom fields
|
||||
.SYNOPSIS
|
||||
Returns a list of all Snipe-IT custom fields
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Field -url "https://assets.example.com" -token "token..."
|
||||
.EXAMPLE
|
||||
Get-Field -url "https://assets.example.com" -token "token..."
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Departments
|
||||
Gets a list of Snipe-it Departments
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Departments data
|
||||
|
|
@ -27,7 +27,10 @@ Users API Key for Snipeit, can be set using Set-Info command
|
|||
Get-Department -url "https://assets.example.com" -token "token..."
|
||||
|
||||
.EXAMPLE
|
||||
Get-Department -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Department1" }
|
||||
Get-Department -search Department1
|
||||
|
||||
.EXAMPLE
|
||||
Get-Department -id 1
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Fieldsets
|
||||
Gets a list of Snipe-it Fieldsets
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Licenses
|
||||
Gets a list of Snipe-it Licenses
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Licenses data
|
||||
|
|
@ -25,10 +25,10 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-License -url "https://assets.example.com" -token "token..."
|
||||
Get-License -search SomeLicense
|
||||
|
||||
.EXAMPLE
|
||||
Get-License -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "License" }
|
||||
Get-License -id 1
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -24,10 +24,12 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Manufacturer -url "https://assets.example.com" -token "token..."
|
||||
Get-Manufacturer -search HP
|
||||
Search all manufacturers for string HP
|
||||
|
||||
.EXAMPLE
|
||||
Get-Manufacturer -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "HP" }
|
||||
Get-Manufacturer -id 3
|
||||
Returns manufacturer with id 3
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Models
|
||||
Gets a list of Snipe-it Models
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Models data
|
||||
|
|
@ -24,10 +24,10 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Model -url "https://assets.example.com" -token "token..."
|
||||
Get-Model -search "DL380"
|
||||
|
||||
.EXAMPLE
|
||||
Get-Model -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "DL380" }
|
||||
Get-Model -id 1
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Locations
|
||||
Gets a list of Snipe-it Locations
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Locations data
|
||||
|
|
@ -24,10 +24,10 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Location -url "https://assets.example.com" -token "token..."
|
||||
Get-Location -search Location1
|
||||
|
||||
.EXAMPLE
|
||||
Get-Location -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Location1" }
|
||||
Get-Location -id 3
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Gets a list of Snipe-it Status Labels
|
||||
Gets a list of Snipe-it Status Labels
|
||||
|
||||
.PARAMETER search
|
||||
A text string to search the Status Labels data
|
||||
|
|
@ -24,10 +24,10 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Status -url "https://assets.example.com" -token "token..."
|
||||
Get-Status -search "Ready to Deploy"
|
||||
|
||||
.EXAMPLE
|
||||
Get-Status -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Ready to Deploy" }
|
||||
Get-Status -id 3
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -24,10 +24,10 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-Supplier -url "https://assets.example.com" -token "token..."
|
||||
Get-Supplier -search MySupplier
|
||||
|
||||
.EXAMPLE
|
||||
Get-Supplier -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "MySupplier" }
|
||||
Get-Supplier -id 2
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -8,6 +8,12 @@ A text string to search the User data
|
|||
.PARAMETER id
|
||||
A id of specific User
|
||||
|
||||
.PARAMETER username
|
||||
Search string for username field
|
||||
|
||||
.PARAMETER email
|
||||
Search string for email field
|
||||
|
||||
.PARAMETER limit
|
||||
Specify the number of results you wish to return. Defaults to 50. Defines batch size for -all
|
||||
|
||||
|
|
@ -24,12 +30,18 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Get-User -url "https://assets.example.com" -token "token..."
|
||||
Get-User -search SomeSurname
|
||||
|
||||
.EXAMPLE
|
||||
Get-User -url "https://assets.example.com" -token "token..." | Where-Object {$_.username -eq "stephenm" }
|
||||
Get-User -id 3
|
||||
|
||||
.EXAMPLE
|
||||
Get-User -username someuser
|
||||
|
||||
.EXAMPLE
|
||||
Get-User -email user@somedomain.com
|
||||
#>
|
||||
|
||||
function Get-User() {
|
||||
Param(
|
||||
[string]$search,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,62 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Creates new accessory on Snipe-It system
|
||||
|
||||
.DESCRIPTION
|
||||
Creates new accessory on Snipe-It system
|
||||
|
||||
.PARAMETER name
|
||||
Accessory name
|
||||
|
||||
.PARAMETER qty
|
||||
Quantity of the accessory you have
|
||||
|
||||
.PARAMETER category_id
|
||||
ID number of the category the accessory belongs to
|
||||
|
||||
.PARAMETER company_id
|
||||
ID Number of the company the accessory is assigned to
|
||||
|
||||
.PARAMETER manufacturer_id
|
||||
ID number of the manufacturer for this accessory.
|
||||
|
||||
.PARAMETER order_number
|
||||
Order number for this accessory.
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
.PARAMETER order_number
|
||||
Order number for this accessory.
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
.PARAMETER supplier_id
|
||||
ID number of the supplier for this accessory
|
||||
|
||||
.PARAMETER location_id
|
||||
ID number of the location the accessory is assigned to
|
||||
|
||||
.PARAMETER min_qty
|
||||
Min quantity of the accessory before alert is triggered
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
New-Accessory -name "Accessory" -qty 3 -category_id 1
|
||||
|
||||
#>
|
||||
function New-Accessory() {
|
||||
[CmdletBinding(
|
||||
SupportsShouldProcess = $true,
|
||||
|
|
@ -29,11 +87,14 @@ function New-Accessory() {
|
|||
|
||||
[datetime]$purchase_date,
|
||||
|
||||
[bool]$requestable,
|
||||
[int]$min_qty,
|
||||
|
||||
[ValidateRange(1, [int]::MaxValue)]
|
||||
[int]$supplier_id,
|
||||
|
||||
[ValidateRange(1, [int]::MaxValue)]
|
||||
[int]$location_id,
|
||||
|
||||
[parameter(mandatory = $true)]
|
||||
[string]$url,
|
||||
|
||||
|
|
|
|||
|
|
@ -1,61 +1,68 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Add a new Asset to Snipe-it asset system
|
||||
.SYNOPSIS
|
||||
Add a new Asset to Snipe-it asset system
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
|
||||
|
||||
.PARAMETER status_id
|
||||
Required Status ID of the asset, this can be got using Get-Status
|
||||
.PARAMETER status_id
|
||||
Required Status ID of the asset, this can be got using Get-Status
|
||||
|
||||
.PARAMETER model_id
|
||||
Required Model ID of the asset, this can be got using Get-Model
|
||||
.PARAMETER model_id
|
||||
Required Model ID of the asset, this can be got using Get-Model
|
||||
|
||||
.PARAMETER name
|
||||
Optional Name of the Asset
|
||||
.PARAMETER name
|
||||
Optional Name of the Asset
|
||||
|
||||
.PARAMETER asset_tag
|
||||
Asset Tag for the Asset, not required when snipe asset_tag autogeneration is on.
|
||||
.PARAMETER asset_tag
|
||||
Asset Tag for the Asset, not required when snipe asset_tag autogeneration is on.
|
||||
|
||||
.PARAMETER serial
|
||||
Optional Serial number of the Asset
|
||||
.PARAMETER serial
|
||||
Optional Serial number of the Asset
|
||||
|
||||
.PARAMETER company_id
|
||||
Optional Company id
|
||||
.PARAMETER company_id
|
||||
Optional Company id
|
||||
|
||||
.PARAMETER order_number
|
||||
Optional Order number
|
||||
.PARAMETER order_number
|
||||
Optional Order number
|
||||
|
||||
.PARAMETER notes
|
||||
Optional Notes
|
||||
.PARAMETER notes
|
||||
Optional Notes
|
||||
|
||||
.PARAMETER warranty_monhts
|
||||
Optional Warranty lenght of the Asset in months
|
||||
.PARAMETER warranty_monhts
|
||||
Optional Warranty lenght of the Asset in months
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Optional Purchase cost of the Asset
|
||||
.PARAMETER purchase_cost
|
||||
Optional Purchase cost of the Asset
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Optional Purchase cost of the Asset
|
||||
.PARAMETER purchase_date
|
||||
Optional Purchase cost of the Asset
|
||||
|
||||
.PARAMETER rtd_location_id
|
||||
Optional Default location id for the asset
|
||||
.PARAMETER rtd_location_id
|
||||
Optional Default location id for the asset
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.PARAMETER customfields
|
||||
Hastable of custom fields and extra fields that need passing through to Snipeit
|
||||
.PARAMETER customfields
|
||||
Hastable of custom fields and extra fields that need passing through to Snipeit.
|
||||
Use internal field names from snipeit .You can use Get-CustomField to get internal field names.
|
||||
|
||||
.EXAMPLE
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1"
|
||||
.EXAMPLE
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1"
|
||||
Create asset with automatic tag if tag genaration is enabled on snipe-it, other wise without tag
|
||||
|
||||
.EXAMPLE
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1" -CustomValues = @{ "_snipeit_os_5 = "Windows 10 Pro" }
|
||||
.EXAMPLE
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1" -asset_tag "DEV123"
|
||||
Specifying asset tag when creating asset
|
||||
|
||||
.EXAMPLE
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1" -CustomValues = @{ "_snipeit_os_5" = "Windows 10 Pro" }
|
||||
Using customfields when creating asset.
|
||||
#>
|
||||
|
||||
function New-Asset()
|
||||
|
|
|
|||
|
|
@ -1,3 +1,44 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Add a new Asset maintenence to Snipe-it asset system
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
|
||||
|
||||
.PARAMETER title
|
||||
Required Title of maintenance
|
||||
|
||||
.PARAMETER asset_id
|
||||
Required ID of the asset, this can be got using Get-Asset
|
||||
|
||||
.PARAMETER supplier_id
|
||||
Required maintenance supplier
|
||||
|
||||
.PARAMETER start_date
|
||||
Required start date
|
||||
|
||||
.PARAMETER is_warranty
|
||||
Optional Maintenance done under warranty
|
||||
|
||||
.PARAMETER cost
|
||||
Optional cost
|
||||
|
||||
.PARAMETER comletion_date
|
||||
Optional completion date
|
||||
|
||||
.PARAMETER notes
|
||||
Optional cost
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
New-AssetMaintenence -asset_id 1 -supplier_id 1 -title "replace keyboard" -start_date 2021-01-01
|
||||
#>
|
||||
function New-AssetMaintenance() {
|
||||
[CmdletBinding(
|
||||
SupportsShouldProcess = $true,
|
||||
|
|
|
|||
|
|
@ -1,18 +1,18 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Add a new Audit to Snipe-it asset system
|
||||
.SYNOPSIS
|
||||
Add a new Audit to Snipe-it asset system
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
|
||||
.PARAMETER Tag
|
||||
The asset tag of the asset you wish to audit
|
||||
.PARAMETER Tag
|
||||
The asset tag of the asset you wish to audit
|
||||
|
||||
.PARAMETER Location_id
|
||||
ID of the location you want to associate with the audit
|
||||
.PARAMETER Location_id
|
||||
ID of the location you want to associate with the audit
|
||||
|
||||
.EXAMPLE
|
||||
New-Audit -tag 1 -location_id "Location of Audit"
|
||||
.EXAMPLE
|
||||
New-Audit -tag 1 -location_id 1
|
||||
|
||||
#>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,20 +1,28 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
# Create a new Snipe-IT Category
|
||||
Create a new Snipe-IT Category
|
||||
|
||||
.PARAMETER name
|
||||
Name of new category to be created
|
||||
|
||||
.PARAMETER type
|
||||
Type of new category to be created (asset, accessory, consumable, component, license)
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.PARAMETER use_default_eula
|
||||
If switch is present, use the primary default EULA
|
||||
|
||||
.PARAMETER require_acceptance
|
||||
If switch is present, require users to confirm acceptance of assets in this category
|
||||
|
||||
.PARAMETER checkin_email
|
||||
If switch is present, send email to user on checkin/checkout
|
||||
|
||||
.EXAMPLE
|
||||
New-Category -name "Laptops" -category_type asset -url "Snipe-IT URL here..." -apiKey "API key here..."
|
||||
#>
|
||||
|
|
|
|||
|
|
@ -1,24 +1,22 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Short description
|
||||
.SYNOPSIS
|
||||
Creates a new Company
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
.DESCRIPTION
|
||||
Creates new company on Snipe-It system
|
||||
|
||||
.PARAMETER name
|
||||
Parameter description
|
||||
.PARAMETER name
|
||||
Comapany name
|
||||
|
||||
.PARAMETER url
|
||||
Parameter description
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Parameter description
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
.EXAMPLE
|
||||
New-Company -name "Acme Company"
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
#>
|
||||
|
||||
function New-Company()
|
||||
|
|
|
|||
|
|
@ -1,30 +1,39 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Short description
|
||||
.SYNOPSIS
|
||||
Create a new component
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
.DESCRIPTION
|
||||
Createa new componen on Snipe-It system
|
||||
|
||||
.PARAMETER name
|
||||
Parameter description
|
||||
.PARAMETER name
|
||||
Component name
|
||||
|
||||
.PARAMETER category_id
|
||||
Parameter description
|
||||
.PARAMETER category_id
|
||||
ID number of category
|
||||
|
||||
.PARAMETER qty
|
||||
Parameter description
|
||||
.PARAMETER qty
|
||||
Quantity of the components you have
|
||||
|
||||
.PARAMETER url
|
||||
Parameter description
|
||||
.PARAMETER location_id
|
||||
ID number of the location the accessory is assigned to
|
||||
|
||||
.PARAMETER apiKey
|
||||
Parameter description
|
||||
.PARAMETER purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
.PARAMETER purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
#>
|
||||
|
||||
function New-Component() {
|
||||
|
|
|
|||
|
|
@ -1,30 +1,31 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Short description
|
||||
Creates a department
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
Creates a new department on Snipe-It system
|
||||
|
||||
.PARAMETER name
|
||||
Parameter description
|
||||
Department Name
|
||||
|
||||
.PARAMETER category_id
|
||||
Parameter description
|
||||
.PARAMETER company_id
|
||||
ID number of company
|
||||
|
||||
.PARAMETER qty
|
||||
Parameter description
|
||||
.PARAMETER location_id
|
||||
ID number of location
|
||||
|
||||
.PARAMETER manager_id
|
||||
ID number of manager
|
||||
|
||||
.PARAMETER url
|
||||
Parameter description
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Parameter description
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
New-Department -name "Department1" -company_id 1 -localtion_id 1 -manager_id 3
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
#>
|
||||
|
||||
function New-Department() {
|
||||
|
|
|
|||
|
|
@ -1,3 +1,71 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Creates a licence
|
||||
|
||||
.DESCRIPTION
|
||||
Creates a new licence on Snipe-It system
|
||||
|
||||
.PARAMETER name
|
||||
Name of license being created
|
||||
|
||||
.PARAMETER seats
|
||||
Number of license seats owned.
|
||||
|
||||
.PARAMETER company_id
|
||||
Id number of company license belongs to
|
||||
|
||||
.PARAMETER expiration_date
|
||||
Date of license expiration
|
||||
|
||||
.PARAMETER expiration_date
|
||||
Date of license expiration
|
||||
|
||||
.PARAMETER license_email
|
||||
Email address associated with license
|
||||
|
||||
.PARAMETER license_name
|
||||
Name of license contact person
|
||||
|
||||
.PARAMETER serial
|
||||
Serialnumber of license
|
||||
|
||||
.PARAMETER maintained
|
||||
Maintained status of license
|
||||
|
||||
.PARAMETER manufacturer_id
|
||||
ID number of manufacturer of license.
|
||||
|
||||
.PARAMETER notes
|
||||
License Notes
|
||||
|
||||
.PARAMETER order_number
|
||||
Order number of license purchase
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of license
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date of license purchase
|
||||
|
||||
.PARAMETER reassignable
|
||||
Is license reassignable?
|
||||
|
||||
.PARAMETER supplier_id
|
||||
ID number of license supplier
|
||||
|
||||
.PARAMETER termination_date
|
||||
Termination date for license.
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
New-Licence -name "License" -seats 3 -company_id 1
|
||||
|
||||
#>
|
||||
|
||||
function New-License() {
|
||||
[CmdletBinding(
|
||||
|
|
|
|||
|
|
@ -8,6 +8,9 @@
|
|||
.PARAMETER name
|
||||
Name of the Asset Model
|
||||
|
||||
.PARAMETER model_number
|
||||
Model number of the Asset Model
|
||||
|
||||
.PARAMETER category_id
|
||||
Category ID that the asset belongs to this can be got using Get-Category
|
||||
|
||||
|
|
|
|||
|
|
@ -1,64 +1,65 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Short description
|
||||
Creates a new user
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
Creates a new user to Snipe-IT system
|
||||
|
||||
.PARAMETER first_name
|
||||
Parameter description
|
||||
Users first name
|
||||
|
||||
.PARAMETER last_name
|
||||
Parameter description
|
||||
Users last name
|
||||
|
||||
.PARAMETER username
|
||||
Parameter description
|
||||
Username for user
|
||||
|
||||
.PARAMETER active
|
||||
Parameter description
|
||||
Can user log in to snipe-it?
|
||||
|
||||
.PARAMETER notes
|
||||
Parameter description
|
||||
User Notes
|
||||
|
||||
.PARAMETER jobtitle
|
||||
Parameter description
|
||||
Users job tittle
|
||||
|
||||
.PARAMETER email
|
||||
Parameter description
|
||||
email address
|
||||
|
||||
.PARAMETER phone
|
||||
Parameter description
|
||||
Phone number
|
||||
|
||||
.PARAMETER company_id
|
||||
Parameter description
|
||||
ID number of company users belogs to
|
||||
|
||||
.PARAMETER location_id
|
||||
Parameter description
|
||||
ID number of localtion
|
||||
|
||||
.PARAMETER department_id
|
||||
Parameter description
|
||||
ID number of department
|
||||
|
||||
.PARAMETER manager_id
|
||||
Parameter description
|
||||
ID number of manager
|
||||
|
||||
.PARAMETER employee_num
|
||||
Parameter description
|
||||
Employeenumber
|
||||
|
||||
.PARAMETER ldap_import
|
||||
Mark user as import from ldap
|
||||
|
||||
.PARAMETER url
|
||||
Parameter description
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Parameter description
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
New-user -fist_name It -lastname Snipe -username snipeit -activated $false -company_id 1 -location_id 1 -department_id 1
|
||||
Creates new a new user who can't login to system
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
#>
|
||||
#>
|
||||
function New-User() {
|
||||
|
||||
[CmdletBinding(
|
||||
|
|
|
|||
|
|
@ -5,8 +5,14 @@
|
|||
Long description
|
||||
.PARAMETER ID
|
||||
Unique ID For Asset to be removed
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Remove-Asset -ID 44 -url $url -apiKey $secret -Verbose
|
||||
Remove-Asset -ID 44 -Verbose
|
||||
#>
|
||||
|
||||
function Remove-Asset ()
|
||||
|
|
|
|||
|
|
@ -6,6 +6,12 @@ function Remove-AssetMaintenance {
|
|||
Removes asset maintenance event from Snipe-it asset system by ID
|
||||
.PARAMETER ID
|
||||
Unique ID of the asset maintenance to be removed
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Remove-AssetMaintenance -ID 44 -url $url -apiKey $secret -Verbose
|
||||
#>
|
||||
|
|
|
|||
|
|
@ -5,6 +5,13 @@
|
|||
Long description
|
||||
.PARAMETER ID
|
||||
Unique ID For User to be removed
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Remove-User -ID 44 -url $url -apiKey $secret -Verbose
|
||||
#>
|
||||
|
|
|
|||
|
|
@ -1,3 +1,30 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Checkin asset
|
||||
.DESCRIPTION
|
||||
Checks asset in from current user/localtion/asset
|
||||
|
||||
.PARAMETER ID
|
||||
Unique ID For asset to checkin
|
||||
|
||||
.PARAMETER status_id
|
||||
Change asset status to
|
||||
|
||||
.PARAMETER location_id
|
||||
Location id to change asset location to
|
||||
|
||||
.PARAMETER notes
|
||||
Notes about checkin
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Remove-User -ID 44 -url $url -apiKey $secret -Verbose
|
||||
#>
|
||||
function Reset-AssetOwner() {
|
||||
[CmdletBinding(
|
||||
SupportsShouldProcess = $true,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,62 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Updates accessory on Snipe-It system
|
||||
|
||||
.DESCRIPTION
|
||||
Updates accessory on Snipe-It system
|
||||
|
||||
.PARAMETER name
|
||||
ID number of Accessory on Snipe-It system
|
||||
|
||||
.PARAMETER qty
|
||||
Quantity of the accessory you have
|
||||
|
||||
.PARAMETER category_id
|
||||
ID number of the category the accessory belongs to
|
||||
|
||||
.PARAMETER company_id
|
||||
ID Number of the company the accessory is assigned to
|
||||
|
||||
.PARAMETER manufacturer_id
|
||||
ID number of the manufacturer for this accessory.
|
||||
|
||||
.PARAMETER order_number
|
||||
Order number for this accessory.
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
.PARAMETER order_number
|
||||
Order number for this accessory.
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
.PARAMETER supplier_id
|
||||
ID number of the supplier for this accessory
|
||||
|
||||
.PARAMETER location_id
|
||||
ID number of the location the accessory is assigned to
|
||||
|
||||
.PARAMETER min_qty
|
||||
Min quantity of the accessory before alert is triggered
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Set-Accessory -id 1 -qty 3
|
||||
|
||||
#>
|
||||
function Set-Accessory() {
|
||||
[CmdletBinding(
|
||||
SupportsShouldProcess = $true,
|
||||
|
|
@ -29,7 +87,7 @@ function Set-Accessory() {
|
|||
|
||||
[datetime]$purchase_date,
|
||||
|
||||
[bool]$requestable,
|
||||
[bool]$min_qty,
|
||||
|
||||
[ValidateRange(1, [int]::MaxValue)]
|
||||
[int]$supplier_id,
|
||||
|
|
|
|||
|
|
@ -1,3 +1,38 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Checkout asset
|
||||
.DESCRIPTION
|
||||
Checkout asset to user/localtion/asset
|
||||
|
||||
.PARAMETER ID
|
||||
Unique ID For asset to checkout
|
||||
|
||||
.PARAMETER assigned_id
|
||||
Id of target user , location or asset
|
||||
|
||||
.PARAMETER note
|
||||
Notes about checkout
|
||||
|
||||
.PARAMETER name
|
||||
Optional new asset name. This is useful for changing the asset's name on new checkout,
|
||||
for example, an asset that was named "Anna's Macbook Pro" could be renamed on the fly
|
||||
when it's checked out to Elizabeth, to "Beth's Macbook Pro"
|
||||
|
||||
.PARAMETER expected_checkin
|
||||
Optional date the asset is expected to be checked in
|
||||
|
||||
.PARAMETER checkout_at
|
||||
Optional date to override the checkout time of now
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Remove-User -ID 44 -url $url -apiKey $secret -Verbose
|
||||
#>
|
||||
function Set-AssetOwner()
|
||||
{
|
||||
[CmdletBinding(
|
||||
|
|
@ -15,6 +50,14 @@ function Set-AssetOwner()
|
|||
[ValidateSet("location","asset","user")]
|
||||
[string] $checkout_to_type = "user",
|
||||
|
||||
[string] $name,
|
||||
|
||||
[string] $note,
|
||||
|
||||
[datetime] $expected_checkin,
|
||||
|
||||
[datetime]$checkout_at,
|
||||
|
||||
[parameter(mandatory = $true)]
|
||||
[string]$url,
|
||||
|
||||
|
|
@ -22,9 +65,14 @@ function Set-AssetOwner()
|
|||
[string]$apiKey
|
||||
)
|
||||
|
||||
$Values = @{
|
||||
"id" = $id
|
||||
"checkout_to_type" = $checkout_to_type
|
||||
$Values = . Get-ParameterValue $MyInvocation.MyCommand.Parameters
|
||||
|
||||
if ($Values['expected_checkin']) {
|
||||
$Values['expected_checkin'] = $values['expected_checkin'].ToString("yyyy-MM-dd")
|
||||
}
|
||||
|
||||
if ($Values['checkout_at']) {
|
||||
$Values['checkout_at'] = $values['checkout_at'].ToString("yyyy-MM-dd")
|
||||
}
|
||||
|
||||
switch ($checkout_to_type)
|
||||
|
|
@ -34,6 +82,9 @@ function Set-AssetOwner()
|
|||
'asset' { $Values += @{ "assigned_asset" = $assigned_id } }
|
||||
}
|
||||
|
||||
#This can be removed now
|
||||
if($Values.ContainsKey('assigned_id')){$Values.Remove('assigned_id')}
|
||||
|
||||
$Body = $Values | ConvertTo-Json;
|
||||
|
||||
$Parameters = @{
|
||||
|
|
|
|||
|
|
@ -1,3 +1,43 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Updates component
|
||||
|
||||
.DESCRIPTION
|
||||
Updates component on Snipe-It system
|
||||
|
||||
.PARAMETER id
|
||||
ID number of name
|
||||
|
||||
.PARAMETER name
|
||||
Component name
|
||||
|
||||
.PARAMETER category_id
|
||||
ID number of category
|
||||
|
||||
.PARAMETER qty
|
||||
Quantity of the components you have
|
||||
|
||||
.PARAMETER location_id
|
||||
ID number of the location the accessory is assigned to
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
#>
|
||||
function Set-Component()
|
||||
{
|
||||
[CmdletBinding(
|
||||
|
|
@ -12,6 +52,16 @@ function Set-Component()
|
|||
[parameter(mandatory = $true)]
|
||||
[string]$qty,
|
||||
|
||||
[string]$name,
|
||||
|
||||
[int]$company_id,
|
||||
|
||||
[int]$location_id,
|
||||
|
||||
[datetime]$purchase_date,
|
||||
|
||||
[float]$purchase_cost,
|
||||
|
||||
[parameter(mandatory = $true)]
|
||||
[string]$url,
|
||||
|
||||
|
|
@ -19,11 +69,13 @@ function Set-Component()
|
|||
[string]$apiKey
|
||||
)
|
||||
|
||||
$Values = @{
|
||||
"qty" = $qty
|
||||
$values = . Get-ParameterValue $MyInvocation.MyCommand.Parameters
|
||||
|
||||
if ($values['purchase_date']) {
|
||||
$values['purchase_date'] = $values['purchase_date'].ToString("yyyy-MM-dd")
|
||||
}
|
||||
|
||||
$Body = $Values | ConvertTo-Json;
|
||||
$Body = $values | ConvertTo-Json;
|
||||
|
||||
$Parameters = @{
|
||||
Uri = "$url/api/v1/components/$id"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,18 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Sets authetication information
|
||||
.DESCRIPTION
|
||||
Set apikey and url user to connect Snipe-It system
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Set-Info -url $url -apiKey -Verbose
|
||||
#>
|
||||
function Set-Info {
|
||||
[CmdletBinding()]
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage('PSUseShouldProcessForStateChangingFunctions', '')]
|
||||
|
|
|
|||
|
|
@ -1,3 +1,74 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Updates a licence
|
||||
|
||||
.DESCRIPTION
|
||||
Updates licence on Snipe-It system
|
||||
|
||||
.PARAMETER id
|
||||
ID number of licence
|
||||
|
||||
.PARAMETER name
|
||||
Name of license
|
||||
|
||||
.PARAMETER seats
|
||||
Number of license seats owned.
|
||||
|
||||
.PARAMETER company_id
|
||||
Id number of company license belongs to
|
||||
|
||||
.PARAMETER expiration_date
|
||||
Date of license expiration
|
||||
|
||||
.PARAMETER expiration_date
|
||||
Date of license expiration
|
||||
|
||||
.PARAMETER license_email
|
||||
Email address associated with license
|
||||
|
||||
.PARAMETER license_name
|
||||
Name of license contact person
|
||||
|
||||
.PARAMETER serial
|
||||
Serialnumber of license
|
||||
|
||||
.PARAMETER maintained
|
||||
Maintained status of license
|
||||
|
||||
.PARAMETER manufacturer_id
|
||||
ID number of manufacturer of license.
|
||||
|
||||
.PARAMETER notes
|
||||
License Notes
|
||||
|
||||
.PARAMETER order_number
|
||||
Order number of license purchase
|
||||
|
||||
.PARAMETER purchase_cost
|
||||
Cost of license
|
||||
|
||||
.PARAMETER purchase_date
|
||||
Date of license purchase
|
||||
|
||||
.PARAMETER reassignable
|
||||
Is license reassignable?
|
||||
|
||||
.PARAMETER supplier_id
|
||||
ID number of license supplier
|
||||
|
||||
.PARAMETER termination_date
|
||||
Termination date for license.
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
Set-Licence -name "License" -seats 3 -company_id 1
|
||||
|
||||
#>
|
||||
|
||||
function Set-License() {
|
||||
[CmdletBinding(
|
||||
|
|
|
|||
|
|
@ -1,3 +1,38 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Updates Model on Snipe-it asset system
|
||||
|
||||
.DESCRIPTION
|
||||
Updates Model on Snipe-it asset system
|
||||
|
||||
.PARAMETER id
|
||||
ID number of the Asset Model
|
||||
|
||||
.PARAMETER name
|
||||
Name of the Asset Model
|
||||
|
||||
.PARAMETER model_number
|
||||
Model number of the Asset Model
|
||||
|
||||
.PARAMETER category_id
|
||||
Category ID that the asset belongs to this can be got using Get-Category
|
||||
|
||||
.PARAMETER manufacturer_id
|
||||
Manufacturer ID that the asset belongs to this can be got using Get-Manufacturer
|
||||
|
||||
.PARAMETER fieldset_id
|
||||
Fieldset ID that the asset uses (Custom fields)
|
||||
|
||||
.PARAMETER url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
New-Model -name "DL380" -manufacturer_id 2 -fieldset_id 2 -category_id 1
|
||||
#>
|
||||
|
||||
function Set-Model() {
|
||||
[CmdletBinding(
|
||||
SupportsShouldProcess = $true,
|
||||
|
|
|
|||
|
|
@ -1,64 +1,65 @@
|
|||
<#
|
||||
.SYNOPSIS
|
||||
Short description
|
||||
Creates a new user
|
||||
|
||||
.DESCRIPTION
|
||||
Long description
|
||||
|
||||
.PARAMETER id
|
||||
Parameter description
|
||||
Creates a new user to Snipe-IT system
|
||||
|
||||
.PARAMETER first_name
|
||||
Parameter description
|
||||
Users first name
|
||||
|
||||
.PARAMETER last_name
|
||||
Parameter description
|
||||
Users last name
|
||||
|
||||
.PARAMETER userName
|
||||
Parameter description
|
||||
.PARAMETER username
|
||||
Username for user
|
||||
|
||||
.PARAMETER jobtitle
|
||||
Parameter description
|
||||
|
||||
.PARAMETER email
|
||||
Parameter description
|
||||
|
||||
.PARAMETER phone
|
||||
Parameter description
|
||||
|
||||
.PARAMETER company_id
|
||||
Parameter description
|
||||
|
||||
.PARAMETER location_id
|
||||
Parameter description
|
||||
|
||||
.PARAMETER department_id
|
||||
Parameter description
|
||||
|
||||
.PARAMETER manager_id
|
||||
Parameter description
|
||||
|
||||
.PARAMETER employee_num
|
||||
Parameter description
|
||||
|
||||
.PARAMETER activated
|
||||
Parameter description
|
||||
.PARAMETER active
|
||||
Can user log in to snipe-it?
|
||||
|
||||
.PARAMETER notes
|
||||
Parameter description
|
||||
User Notes
|
||||
|
||||
.PARAMETER jobtitle
|
||||
Users job tittle
|
||||
|
||||
.PARAMETER email
|
||||
email address
|
||||
|
||||
.PARAMETER phone
|
||||
Phone number
|
||||
|
||||
.PARAMETER company_id
|
||||
ID number of company users belogs to
|
||||
|
||||
.PARAMETER location_id
|
||||
ID number of localtion
|
||||
|
||||
.PARAMETER department_id
|
||||
ID number of department
|
||||
|
||||
.PARAMETER manager_id
|
||||
ID number of manager
|
||||
|
||||
.PARAMETER employee_num
|
||||
Employeenumber
|
||||
|
||||
.PARAMETER ldap_import
|
||||
Mark user as import from ldap
|
||||
|
||||
.PARAMETER url
|
||||
Parameter description
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
.PARAMETER apiKey
|
||||
Parameter description
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
.EXAMPLE
|
||||
An example
|
||||
Update-user -id 3 -fist_name It -lastname Snipe -username snipeit -activated $false -company_id 1 -location_id 1 -department_id 1
|
||||
Updates user with id 3
|
||||
|
||||
.NOTES
|
||||
General notes
|
||||
#>
|
||||
#>
|
||||
function Set-User() {
|
||||
|
||||
[CmdletBinding(
|
||||
|
|
@ -103,16 +104,7 @@ function Set-User() {
|
|||
[string]$apiKey
|
||||
)
|
||||
|
||||
$Values = @{}
|
||||
|
||||
#$exclude = @('id', 'url', 'apiKey')
|
||||
#$excludeRegex = [string]::Join('|', $exclude) # create the regex
|
||||
|
||||
foreach ($psbp in $PSBoundParameters.GetEnumerator()) {
|
||||
#if ($psbp.Key -notmatch $excludeRegex) {
|
||||
$Values.Add($psbp.Key, $psbp.Value)
|
||||
#}
|
||||
}
|
||||
$Values = . Get-ParameterValue $MyInvocation.MyCommand.Parameters
|
||||
|
||||
$Body = $Values | ConvertTo-Json;
|
||||
|
||||
|
|
|
|||
229
docs/Get-Accessory.md
Normal file
229
docs/Get-Accessory.md
Normal file
|
|
@ -0,0 +1,229 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Accessory
|
||||
|
||||
## SYNOPSIS
|
||||
Gets a list of Snipe-it Accessories
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Accessory [[-search] <String>] [[-company_id] <Int32>] [[-category_id] <Int32>]
|
||||
[[-manufacturer_id] <Int32>] [[-supplier_id] <Int32>] [[-sort] <String>] [[-order] <String>]
|
||||
[[-limit] <Int32>] [[-offset] <Int32>] [-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Gets a list of Snipe-it Accessories
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Accessory -search Keyboard
|
||||
```
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Accessory -id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
{{ Fill category_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{ Fill company_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
{{ Fill manufacturer_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Result offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Accessory data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -sort
|
||||
{{ Fill sort Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: Created_at
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -supplier_id
|
||||
{{ Fill supplier_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 10
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,138 +1,119 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version:
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Asset
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Assets
|
||||
Gets a list of Snipe-it Assets or specific asset
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Asset [[-search] <String>] [[-order_number] <Int32>] [[-model_id] <Int32>] [[-category_id] <Int32>]
|
||||
[[-manufacturer_id] <Int32>] [[-company_id] <Int32>] [[-location_id] <Int32>] [[-status] <String>]
|
||||
[[-status_id] <Int32>] [[-sort] <String>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-url] <String> [-apiKey] <String>
|
||||
Get-Asset [[-search] <String>] [[-id] <String>] [[-asset_tag] <String>] [[-asset_serial] <String>]
|
||||
[[-order_number] <Int32>] [[-model_id] <Int32>] [[-category_id] <Int32>] [[-manufacturer_id] <Int32>]
|
||||
[[-company_id] <Int32>] [[-location_id] <Int32>] [[-depreciation_id] <Int32>] [[-requestable] <Boolean>]
|
||||
[[-status] <String>] [[-status_id] <Int32>] [[-sort] <String>] [[-order] <String>] [[-limit] <Int32>]
|
||||
[[-offset] <Int32>] [-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Asset -url "https://assets.example.com" -token "token..."
|
||||
Get-Asset -url "https://assets.example.com"-token "token..."
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Asset -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "MyMachine" }
|
||||
Get-Asset -search "myMachine"-url "https://assets.example.com"-token "token..."
|
||||
```
|
||||
|
||||
### EXAMPLE 3
|
||||
```
|
||||
Get-Asset -search "myMachine"-url "https://assets.example.com"-token "token..."
|
||||
```
|
||||
|
||||
### EXAMPLE 4
|
||||
```
|
||||
Get-Asset -asset_tag "myAssetTag"-url "https://assets.example.com"-token "token..."
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Required: True
|
||||
Position: 20
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
{{Fill order_number Description}}
|
||||
### -asset_serial
|
||||
Exact asset serialnumber to query
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -model_id
|
||||
{{Fill model_id Description}}
|
||||
### -asset_tag
|
||||
Exact asset tag to query
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
{{Fill category_id Description}}
|
||||
Optionally restrict asset results to this category ID
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
{{Fill manufacturer_id Description}}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{Fill company_id Description}}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
{{Fill location_id Description}}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
|
|
@ -141,28 +122,13 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -status
|
||||
{{Fill status Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -status_id
|
||||
{{Fill status_id Description}}
|
||||
### -company_id
|
||||
Optionally restrict asset results to this company ID
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
|
|
@ -171,61 +137,213 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -sort
|
||||
{{Fill sort Description}}
|
||||
### -depreciation_id
|
||||
{{ Fill depreciation_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: Created_at
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{Fill order Description}}
|
||||
### -id
|
||||
ID number of excact snipeit asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: Desc
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
{{Fill limit Description}}
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Position: 17
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
{{Fill offset Description}}
|
||||
### -location_id
|
||||
Optionally restrict asset results to this location ID
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
Optionally restrict asset results to this manufacturer ID
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -model_id
|
||||
Optionally restrict asset results to this asset model ID
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 18
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
Specify the order (asc or desc) you wish to order by on your sort column
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 16
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
Optionally restrict asset results to this order number
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -requestable
|
||||
{{ Fill requestable Description }}
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the assets data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -sort
|
||||
Specify the column name you wish to sort by
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 15
|
||||
Default value: Created_at
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -status
|
||||
Optionally restrict asset results to one of these status types: RTD, Deployed, Undeployable, Deleted, Archived, Requestable
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -status_id
|
||||
Optionally restrict asset results to this status label ID
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 14
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -237,29 +355,17 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 14
|
||||
Position: 19
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 15
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -268,4 +374,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
188
docs/Get-AssetMaintenance.md
Normal file
188
docs/Get-AssetMaintenance.md
Normal file
|
|
@ -0,0 +1,188 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-AssetMaintenance
|
||||
|
||||
## SYNOPSIS
|
||||
Lists Snipe-it Assets Maintenances
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-AssetMaintenance [[-search] <String>] [[-asset_id] <Int32>] [[-sort] <String>] [[-order] <String>]
|
||||
[[-limit] <Int32>] [-all] [[-offset] <Int32>] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-AssetMaintenances -url "https://assets.example.com" -token "token..."
|
||||
```
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-AssetMaintenances -search "myMachine" -url "https://assets.example.com" -token "token..."
|
||||
```
|
||||
|
||||
### EXAMPLE 3
|
||||
```
|
||||
Get-AssetMaintenances -search "myMachine" -url "https://assets.example.com" -token "token..."
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -asset_id
|
||||
Asset ID of the asset you'd like to return maintenances for
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
Specify the order (asc or desc) you wish to order by on your sort column
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
Search string
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -sort
|
||||
Specify the column name you wish to sort by
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Created_at
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,64 +1,50 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version:
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Category
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Categories
|
||||
Gets a list of Snipe-it Categories
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Category [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Category [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Category -url "https://assets.example.com" -token "token..."
|
||||
Get-Category -id 1
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Category -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Laptop" }
|
||||
Get-Category -search "Laptop"
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
|
@ -69,15 +55,110 @@ Users API Key for Snipeit, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Category
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Categories data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
Url of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
|
@ -85,4 +166,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,45 +1,142 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version:
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Company
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Companies
|
||||
Gets a list of Snipe-it Companies
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Company [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Company [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Company -url "https://assets.example.com" -token "token..."
|
||||
Get-Company
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
Gets all companies
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Company -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Company1" }
|
||||
Get-Company -id 1
|
||||
```
|
||||
|
||||
Gets specific company
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Company
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Companies data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -54,29 +151,17 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -85,4 +170,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,64 +1,62 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version:
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Component
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Components
|
||||
Gets a list of Snipe-it Components
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Component [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Component [[-search] <String>] [[-id] <String>] [[-category_id] <Int32>] [[-company_id] <Int32>]
|
||||
[[-location_id] <Int32>] [[-order] <String>] [[-sort] <String>] [[-limit] <Int32>] [[-offset] <Int32>] [-all]
|
||||
[-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Component -url "https://assets.example.com" -token "token..."
|
||||
Get-Component
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
Returns all components
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Component -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Memory" }
|
||||
Get-Component -search display
|
||||
```
|
||||
|
||||
Returns search results containeing string display
|
||||
|
||||
### EXAMPLE 3
|
||||
```
|
||||
Get-Component -id
|
||||
```
|
||||
|
||||
Returns specific component
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
|
@ -69,15 +67,170 @@ Users API Key for Snipeit, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
{{ Fill category_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{ Fill company_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Component
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
{{ Fill location_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Components data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -sort
|
||||
{{ Fill sort Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: Created_at
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system,can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 10
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
|
@ -85,4 +238,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
70
docs/Get-CustomField.md
Normal file
70
docs/Get-CustomField.md
Normal file
|
|
@ -0,0 +1,70 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-CustomField
|
||||
|
||||
## SYNOPSIS
|
||||
Returns a list of all Snipe-IT custom fields
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-CustomField [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Field -url "https://assets.example.com" -token "token..."
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,64 +1,55 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version:
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Department
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Departments
|
||||
Gets a list of Snipe-it Departments
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Department [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Department [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-all] [[-sort] <String>] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Department -url "https://assets.example.com" -token "token..."
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Department -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Department1" }
|
||||
Get-Department -search Department1
|
||||
```
|
||||
|
||||
### EXAMPLE 3
|
||||
```
|
||||
Get-Department -id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
|
@ -69,15 +60,125 @@ Users API Key for Snipeit, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Department
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Departments data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -sort
|
||||
{{ Fill sort Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: Created_at
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
|
@ -85,4 +186,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
75
docs/Get-Fieldset.md
Normal file
75
docs/Get-Fieldset.md
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Fieldset
|
||||
|
||||
## SYNOPSIS
|
||||
Gets a list of Snipe-it Fieldsets
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Fieldset [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Fieldset -url "https://assets.example.com" -token "token..."
|
||||
```
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Fieldset -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Windows" }
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
|
|
@ -13,33 +13,130 @@ schema: 2.0.0
|
|||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Manufacturer [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Manufacturer [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>]
|
||||
[[-offset] <Int32>] [-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Manufacturer -url "https://assets.example.com" -token "token..."
|
||||
Get-Manufacturer -search HP
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
Search all manufacturers for string HP
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Manufacturer -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "HP" }
|
||||
Get-Manufacturer -id 3
|
||||
```
|
||||
|
||||
Returns manufacturer with id 3
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Manufactuter
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Manufactures data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -54,29 +151,17 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -85,4 +170,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,45 +1,138 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Model
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Models
|
||||
Gets a list of Snipe-it Models
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Model [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Model [[-search] <String>] [[-id] <Int32>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Models -url "https://assets.example.com" -token "token..."
|
||||
Get-Model -search "DL380"
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Models -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "DL380" }
|
||||
Get-Model -id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific model
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Models data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -54,29 +147,17 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -85,4 +166,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
168
docs/Get-SnipeitLocation.md
Normal file
168
docs/Get-SnipeitLocation.md
Normal file
|
|
@ -0,0 +1,168 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-SnipeitLocation
|
||||
|
||||
## SYNOPSIS
|
||||
Gets a list of Snipe-it Locations
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-SnipeitLocation [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>]
|
||||
[[-offset] <Int32>] [-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Location -search Location1
|
||||
```
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Location -id 3
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Locations data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,45 +1,138 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Get-Status
|
||||
|
||||
## SYNOPSIS
|
||||
# Gets a list of Snipe-it Status Labels
|
||||
Gets a list of Snipe-it Status Labels
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Status [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Status [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Status -url "https://assets.example.com" -token "token..."
|
||||
Get-Status -search "Ready to Deploy"
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Status -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "Ready to Deploy" }
|
||||
Get-Status -id 3
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Status Label
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Status Labels data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -54,29 +147,17 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -85,4 +166,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
|
|
@ -13,33 +13,126 @@ schema: 2.0.0
|
|||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-Supplier [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-Supplier [[-search] <String>] [[-id] <String>] [[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>]
|
||||
[-all] [-url] <String> [-apiKey] <String> [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-Supplier -url "https://assets.example.com" -token "token..."
|
||||
Get-Supplier -search MySupplier
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-Supplier -url "https://assets.example.com" -token "token..." | Where-Object {$_.name -eq "MySupplier" }
|
||||
Get-Supplier -id 2
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific Suplier
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the Supliers data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -54,29 +147,17 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -85,4 +166,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
220
docs/Get-User.md
220
docs/Get-User.md
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
|
|
@ -13,33 +13,213 @@ schema: 2.0.0
|
|||
## SYNTAX
|
||||
|
||||
```
|
||||
Get-User [[-search] <String>] [-url] <String> [-apiKey] <String>
|
||||
Get-User [[-search] <String>] [[-id] <String>] [[-company_id] <Int32>] [[-location_id] <Int32>]
|
||||
[[-group_id] <Int32>] [[-department_id] <Int32>] [[-username] <String>] [[-email] <String>]
|
||||
[[-order] <String>] [[-limit] <Int32>] [[-offset] <Int32>] [-all] [-url] <String> [-apiKey] <String>
|
||||
[<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Get-User -url "https://assets.example.com" -token "token..."
|
||||
Get-User -search SomeSurname
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Get-User -url "https://assets.example.com" -token "token..." | Where-Object {$_.username -eq "stephenm" }
|
||||
Get-User -id 3
|
||||
```
|
||||
|
||||
### EXAMPLE 3
|
||||
```
|
||||
Get-User -username someuser
|
||||
```
|
||||
|
||||
### EXAMPLE 4
|
||||
```
|
||||
Get-User -email user@somedomain.com
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -search
|
||||
{{Fill search Description}}
|
||||
### -all
|
||||
A return all results, works with -offset and other parameters
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 13
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{ Fill company_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -department_id
|
||||
{{ Fill department_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -email
|
||||
Search string for email field
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -group_id
|
||||
{{ Fill group_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
A id of specific User
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -limit
|
||||
Specify the number of results you wish to return.
|
||||
Defaults to 50.
|
||||
Defines batch size for -all
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: 50
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
{{ Fill location_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -offset
|
||||
Offset to use
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order
|
||||
{{ Fill order Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: Desc
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -search
|
||||
A text string to search the User data
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -54,30 +234,33 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
### -username
|
||||
Search string for username field
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
|
@ -85,4 +268,3 @@ Accept wildcard characters: False
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
|
|
@ -13,8 +13,11 @@ Add a new Asset to Snipe-it asset system
|
|||
## SYNTAX
|
||||
|
||||
```
|
||||
New-Asset [[-tag] <String>] [-Name] <String> [-Status_id] <Int32> [-Model_id] <Int32> [-url] <String>
|
||||
[-apiKey] <String> [[-customfields] <Hashtable>] [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
New-Asset [-status_id] <Int32> [-model_id] <Int32> [[-name] <String>] [[-asset_tag] <String>]
|
||||
[[-serial] <String>] [[-company_id] <Int32>] [[-order_number] <String>] [[-notes] <String>]
|
||||
[[-warranty_months] <Int32>] [[-purchase_cost] <String>] [[-purchase_date] <String>] [[-supplier_id] <Int32>]
|
||||
[[-rtd_location_id] <Int32>] [-url] <String> [-apiKey] <String> [[-customfields] <Hashtable>] [-WhatIf]
|
||||
[-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
|
|
@ -22,73 +25,235 @@ Long description
|
|||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1"
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
Create asset with automatic tag if tag genaration is enabled on snipe-it, other wise without tag
|
||||
|
||||
### EXAMPLE 2
|
||||
```
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1" -customfields = @{ "_snipeit_os_5" = "Windows 10 Pro" }
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1" -asset_tag "DEV123"
|
||||
```
|
||||
|
||||
Specifying asset tag when creating asset
|
||||
|
||||
### EXAMPLE 3
|
||||
```
|
||||
New-Asset -status_id 1 -model_id 1 -name "Machine1" -CustomValues = @{ "_snipeit_os_5" = "Windows 10 Pro" }
|
||||
```
|
||||
|
||||
Using customfields when creating asset.
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -tag
|
||||
Asset Tag for the Asset
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Name
|
||||
Name of the Asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 15
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Status_id
|
||||
Status ID of the asset, this can be got using Get-Status
|
||||
### -asset_tag
|
||||
Asset Tag for the Asset, not required when snipe asset_tag autogeneration is on.
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases: tag
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
Optional Company id
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Model_id
|
||||
Model ID of the asset, this can be got using Get-Model
|
||||
### -customfields
|
||||
Hastable of custom fields and extra fields that need passing through to Snipeit.
|
||||
Use internal field names from snipeit .You can use Get-CustomField to get internal field names.
|
||||
|
||||
```yaml
|
||||
Type: Hashtable
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 16
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -model_id
|
||||
Required Model ID of the asset, this can be got using Get-Model
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 4
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Optional Name of the Asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
Optional Notes
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
Optional Order number
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_cost
|
||||
Optional Purchase cost of the Asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Optional Purchase cost of the Asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -rtd_location_id
|
||||
Optional Default location id for the asset
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -serial
|
||||
Optional Serial number of the Asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -status_id
|
||||
Required Status ID of the asset, this can be got using Get-Status
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -supplier_id
|
||||
{{ Fill supplier_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -100,40 +265,40 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 5
|
||||
Position: 14
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
### -warranty_months
|
||||
{{ Fill warranty_months Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -customfields
|
||||
Hastable of custom fields and extra fields that need passing through to Snipeit
|
||||
|
||||
```yaml
|
||||
Type: Hashtable
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -155,23 +320,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -180,4 +330,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
239
docs/New-AssetMaintenance.md
Normal file
239
docs/New-AssetMaintenance.md
Normal file
|
|
@ -0,0 +1,239 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-AssetMaintenance
|
||||
|
||||
## SYNOPSIS
|
||||
Add a new Asset maintenence to Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-AssetMaintenance [-asset_id] <Int32> [-supplier_id] <Int32> [-asset_maintenance_type] <String>
|
||||
[-title] <String> [-start_date] <DateTime> [[-completion_date] <DateTime>] [[-is_warranty] <Boolean>]
|
||||
[[-cost] <Decimal>] [[-notes] <String>] [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm]
|
||||
[<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-AssetMaintenence -asset_id 1 -supplier_id 1 -title "replace keyboard" -start_date 2021-01-01
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -asset_id
|
||||
Required ID of the asset, this can be got using Get-Asset
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -asset_maintenance_type
|
||||
{{ Fill asset_maintenance_type Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -completion_date
|
||||
{{ Fill completion_date Description }}
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -cost
|
||||
Optional cost
|
||||
|
||||
```yaml
|
||||
Type: Decimal
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -is_warranty
|
||||
Optional Maintenance done under warranty
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
Optional cost
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -start_date
|
||||
Required start date
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -supplier_id
|
||||
Required maintenance supplier
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -title
|
||||
Required Title of maintenance
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 10
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
177
docs/New-Category.md
Normal file
177
docs/New-Category.md
Normal file
|
|
@ -0,0 +1,177 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-Category
|
||||
|
||||
## SYNOPSIS
|
||||
Create a new Snipe-IT Category
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-Category [-name] <String> [-category_type] <String> [-url] <String> [-apiKey] <String> [-use_default_eula]
|
||||
[-require_acceptance] [-checkin_email] [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Category -name "Laptops" -category_type asset -url "Snipe-IT URL here..." -apiKey "API key here..."
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_type
|
||||
{{ Fill category_type Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -checkin_email
|
||||
If switch is present, send email to user on checkin/checkout
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of new category to be created
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -require_acceptance
|
||||
If switch is present, require users to confirm acceptance of assets in this category
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -use_default_eula
|
||||
If switch is present, use the primary default EULA
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,41 +1,102 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-Component
|
||||
|
||||
## SYNOPSIS
|
||||
Short description
|
||||
Create a new component
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-Component [-name] <String> [-category_id] <String> [-qty] <String> [-url] <String> [-apiKey] <String>
|
||||
[-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
New-Component [-name] <String> [-category_id] <Int32> [-qty] <String> [[-company_id] <Int32>]
|
||||
[[-location_id] <Int32>] [[-purchase_date] <DateTime>] [[-purchase_cost] <Single>] [-url] <String>
|
||||
[-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
Createa new componen on Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
An example
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -name
|
||||
Parameter description
|
||||
### -apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
ID number of category
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{ Fill company_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
ID number of the location the accessory is assigned to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Component name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
|
|
@ -44,28 +105,43 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
Parameter description
|
||||
### -purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: Single
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -qty
|
||||
Parameter description
|
||||
Quantity of the components you have
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
|
|
@ -75,30 +151,30 @@ Accept wildcard characters: False
|
|||
```
|
||||
|
||||
### -url
|
||||
Parameter description
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 4
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Parameter description
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases: cf
|
||||
|
||||
Required: True
|
||||
Position: 5
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -120,23 +196,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -146,4 +207,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
General notes
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
193
docs/New-CustomField.md
Normal file
193
docs/New-CustomField.md
Normal file
|
|
@ -0,0 +1,193 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-CustomField
|
||||
|
||||
## SYNOPSIS
|
||||
Add a new Custom Field to Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-CustomField [-Name] <String> [[-HelpText] <String>] [[-Element] <String>] [[-Format] <String>]
|
||||
[[-field_encrypted] <Boolean>] [[-CustomFormat] <String>] [-url] <String> [-apiKey] <String> [-WhatIf]
|
||||
[-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Add a new Custom Field to Snipe-it asset system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Field -Name "AntivirusInstalled" -Format "BOOLEAN" -HelpText "Is AntiVirus installed on Asset"
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -CustomFormat
|
||||
{{ Fill CustomFormat Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Element
|
||||
{{ Fill Element Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: Text
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -field_encrypted
|
||||
{{ Fill field_encrypted Description }}
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Format
|
||||
{{ Fill Format Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: ANY
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -HelpText
|
||||
{{ Fill HelpText Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Name
|
||||
Name of the Custom Field
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,41 +1,101 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-Department
|
||||
|
||||
## SYNOPSIS
|
||||
Short description
|
||||
Creates a department
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-Department [-name] <String> [[-company_id] <String>] [[-location_id] <String>] [[-manager_id] <String>]
|
||||
[-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
New-Department [-name] <String> [[-company_id] <Int32>] [[-location_id] <Int32>] [[-manager_id] <Int32>]
|
||||
[[-notes] <String>] [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
Creates a new department on Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
An example
|
||||
New-Department -name "Department1" -company_id 1 -localtion_id 1 -manager_id 3
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -name
|
||||
Parameter description
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
ID number of company
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
ID number of location
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
ID number of manager
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Department Name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
|
|
@ -44,73 +104,28 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{Fill company_id Description}}
|
||||
### -notes
|
||||
{{ Fill notes Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
{{Fill location_id Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
{{Fill manager_id Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Parameter description
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
|
|
@ -119,6 +134,21 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
|
@ -135,30 +165,13 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
General notes
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
361
docs/New-License.md
Normal file
361
docs/New-License.md
Normal file
|
|
@ -0,0 +1,361 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-License
|
||||
|
||||
## SYNOPSIS
|
||||
Creates a licence
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-License [-name] <String> [-seats] <Int32> [[-category_id] <Int32>] [[-company_id] <Int32>]
|
||||
[[-expiration_date] <DateTime>] [[-license_email] <MailAddress>] [[-license_name] <String>]
|
||||
[[-maintained] <Boolean>] [[-manufacturer_id] <Int32>] [[-notes] <String>] [[-order_number] <String>]
|
||||
[[-purchase_cost] <Single>] [[-purchase_date] <DateTime>] [[-reassignable] <Boolean>] [[-serial] <String>]
|
||||
[[-supplier_id] <Int32>] [[-termination_date] <DateTime>] [-url] <String> [-apiKey] <String> [-WhatIf]
|
||||
[-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Creates a new licence on Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Licence -name "License" -seats 3 -company_id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 19
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
{{ Fill category_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
Id number of company license belongs to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -expiration_date
|
||||
Date of license expiration
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -license_email
|
||||
Email address associated with license
|
||||
|
||||
```yaml
|
||||
Type: MailAddress
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -license_name
|
||||
Name of license contact person
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -maintained
|
||||
Maintained status of license
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
ID number of manufacturer of license.
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of license being created
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
License Notes
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
Order number of license purchase
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_cost
|
||||
Cost of license
|
||||
|
||||
```yaml
|
||||
Type: Single
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Date of license purchase
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -reassignable
|
||||
Is license reassignable?
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 14
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -seats
|
||||
Number of license seats owned.
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -serial
|
||||
Serialnumber of license
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 15
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -supplier_id
|
||||
ID number of license supplier
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 16
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -termination_date
|
||||
Termination date for license.
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 17
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 18
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,21 +1,21 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-Location
|
||||
|
||||
## SYNOPSIS
|
||||
Add a new Model to Snipe-it asset system
|
||||
Add a new Location to Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-Location [-name] <String> [[-address] <String>] [[-address2] <String>] [[-state] <String>]
|
||||
[[-country] <String>] [[-zip] <String>] [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm]
|
||||
[<CommonParameters>]
|
||||
[[-country] <String>] [[-zip] <String>] [[-parent_id] <Int32>] [[-manager_id] <Int32>] [[-ldap_ou] <String>]
|
||||
[-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
|
|
@ -23,35 +23,20 @@ Long description
|
|||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Model -name "DL380" -manufacturer_id 2 -fieldset_id 2 -category_id 1
|
||||
New-Location -name "Room 1" -address "123 Asset Street" -parent_id 14
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -name
|
||||
Name of the Asset Model
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -address
|
||||
{{Fill address Description}}
|
||||
Address line 1 of the location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
|
|
@ -61,12 +46,12 @@ Accept wildcard characters: False
|
|||
```
|
||||
|
||||
### -address2
|
||||
{{Fill address2 Description}}
|
||||
Address line 2 of the location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
|
|
@ -75,76 +60,151 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -state
|
||||
{{Fill state Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -country
|
||||
{{Fill country Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -zip
|
||||
{{Fill zip Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -country
|
||||
Country of the location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -ldap_ou
|
||||
The LDAP OU of the location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
The manager ID of the location
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of the Location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -parent_id
|
||||
Parent location ID for the location
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -state
|
||||
Address State of the location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 10
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -zip
|
||||
The zip code of the location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -166,23 +226,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -191,4 +236,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
|
|
@ -21,20 +21,35 @@ Long description
|
|||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Manufacturer -name "HP"
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Name
|
||||
Name of the Manufacturer
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
|
|
@ -49,7 +64,7 @@ URL of Snipeit system, can be set using Set-Info command
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
|
|
@ -58,16 +73,16 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases: cf
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -89,23 +104,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -114,4 +114,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
|
|
@ -13,8 +13,9 @@ Add a new Model to Snipe-it asset system
|
|||
## SYNTAX
|
||||
|
||||
```
|
||||
New-Model [-name] <String> [-category_id] <Int32> [-manufacturer_id] <Int32> [-fieldset_id] <Int32>
|
||||
[-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
New-Model [-name] <String> [[-model_number] <String>] [-category_id] <Int32> [-manufacturer_id] <Int32>
|
||||
[[-eol] <Int32>] [-fieldset_id] <Int32> [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm]
|
||||
[<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
|
|
@ -22,23 +23,23 @@ Long description
|
|||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Model -name "DL380" -manufacturer_id 2 -fieldset_id 2 -category_id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -name
|
||||
Name of the Asset Model
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -50,25 +51,25 @@ Category ID that the asset belongs to this can be got using Get-Category
|
|||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
Manufacturer ID that the asset belongs to this can be got using Get-Manufacturer
|
||||
### -eol
|
||||
{{ Fill eol Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -80,7 +81,22 @@ Fieldset ID that the asset uses (Custom fields)
|
|||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
Manufacturer ID that the asset belongs to this can be got using Get-Manufacturer
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 4
|
||||
|
|
@ -89,31 +105,61 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -model_number
|
||||
Model number of the Asset Model
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of the Asset Model
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 5
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases: cf
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -135,23 +181,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -160,4 +191,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
371
docs/New-User.md
371
docs/New-User.md
|
|
@ -1,178 +1,76 @@
|
|||
---
|
||||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# New-User
|
||||
|
||||
## SYNOPSIS
|
||||
Short description
|
||||
Creates a new user
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
New-User [-firstName] <String> [-lastName] <String> [-userName] <String> [[-jobTitle] <String>]
|
||||
[[-email] <String>] [[-phone] <String>] [[-company_id] <Int32>] [[-location_id] <Int32>]
|
||||
[[-department_id] <Int32>] [[-manager_id] <Int32>] [[-employee_num] <String>] [[-ldap_user] <Boolean>]
|
||||
[-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
New-User [-first_name] <String> [-last_name] <String> [-username] <String> [[-password] <String>]
|
||||
[[-activated] <Boolean>] [[-notes] <String>] [[-jobtitle] <String>] [[-email] <String>] [[-phone] <String>]
|
||||
[[-company_id] <Int32>] [[-location_id] <Int32>] [[-department_id] <Int32>] [[-manager_id] <Int32>]
|
||||
[[-employee_num] <String>] [[-ldap_import] <Boolean>] [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm]
|
||||
[<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
Creates a new user to Snipe-IT system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
An example
|
||||
New-user -fist_name It -lastname Snipe -username snipeit -activated $false -company_id 1 -location_id 1 -department_id 1
|
||||
```
|
||||
|
||||
Creates new a new user who can't login to system
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -firstName
|
||||
Parameter description
|
||||
### -activated
|
||||
{{ Fill activated Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -lastName
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -userName
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -jobTitle
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -email
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -phone
|
||||
Parameter description
|
||||
### -apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Required: True
|
||||
Position: 17
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
Parameter description
|
||||
ID number of company users belogs to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -department_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
|
|
@ -181,61 +79,226 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -employee_num
|
||||
Parameter description
|
||||
### -department_id
|
||||
ID number of department
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -email
|
||||
email address
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -ldap_user
|
||||
Parameter description
|
||||
### -employee_num
|
||||
Employeenumber
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 14
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -first_name
|
||||
Users first name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases: firstName
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -jobtitle
|
||||
Users job tittle
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -last_name
|
||||
Users last name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases: lastName
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -ldap_import
|
||||
Mark user as import from ldap
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases: ldap_user
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Position: 15
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
Parameter description
|
||||
### -location_id
|
||||
ID number of localtion
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
ID number of manager
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
User Notes
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 13
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Parameter description
|
||||
### -password
|
||||
{{ Fill password Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -phone
|
||||
Phone number
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 14
|
||||
Position: 16
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -username
|
||||
Username for user
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -257,23 +320,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -283,4 +331,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
General notes
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
116
docs/Remove-Asset.md
Normal file
116
docs/Remove-Asset.md
Normal file
|
|
@ -0,0 +1,116 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Remove-Asset
|
||||
|
||||
## SYNOPSIS
|
||||
Removes Asset to Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Remove-Asset [-ID] <String> [-URL] <String> [-APIKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Remove-Asset -ID 44 -Verbose
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -APIKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -ID
|
||||
Unique ID For Asset to be removed
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -URL
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
116
docs/Remove-User.md
Normal file
116
docs/Remove-User.md
Normal file
|
|
@ -0,0 +1,116 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Remove-User
|
||||
|
||||
## SYNOPSIS
|
||||
Removes User from Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Remove-User [-ID] <String> [-URL] <String> [-APIKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Remove-User -ID 44 -url $url -apiKey $secret -Verbose
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -APIKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -ID
|
||||
Unique ID For User to be removed
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -URL
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
269
docs/Set-Accessory.md
Normal file
269
docs/Set-Accessory.md
Normal file
|
|
@ -0,0 +1,269 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-Accessory
|
||||
|
||||
## SYNOPSIS
|
||||
Updates accessory on Snipe-It system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-Accessory [-id] <Int32> [[-name] <String>] [[-qty] <Int32>] [[-category_id] <Int32>]
|
||||
[[-company_id] <Int32>] [[-manufacturer_id] <Int32>] [[-order_number] <String>] [[-purchase_cost] <Single>]
|
||||
[[-purchase_date] <DateTime>] [[-min_qty] <Boolean>] [[-supplier_id] <Int32>] [-url] <String>
|
||||
[-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Updates accessory on Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Set-Accessory -id 1 -qty 3
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 13
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
ID number of the category the accessory belongs to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
ID Number of the company the accessory is assigned to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
{{ Fill id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
ID number of the manufacturer for this accessory.
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -min_qty
|
||||
Min quantity of the accessory before alert is triggered
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
ID number of Accessory on Snipe-It system
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
Order number for this accessory.
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
```yaml
|
||||
Type: Single
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -qty
|
||||
Quantity of the accessory you have
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -supplier_id
|
||||
ID number of the supplier for this accessory
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
|
@ -1,20 +1,23 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-Asset
|
||||
|
||||
## SYNOPSIS
|
||||
Update a Asset in the Snipe-it asset system
|
||||
Update a specific Asset in the Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-Asset [-id] <Int32> [-Name] <String> [-Status_id] <String> [-Model_id] <String> [-url] <String>
|
||||
[-apiKey] <String> [[-customfields] <Hashtable>] [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
Set-Asset [-id] <Int32> [[-Name] <String>] [[-Status_id] <String>] [[-Model_id] <String>]
|
||||
[[-last_checkout] <DateTime>] [[-assigned_to] <Int32>] [[-company_id] <Int32>] [[-serial] <String>]
|
||||
[[-order_number] <String>] [[-warranty_months] <Int32>] [[-purchase_cost] <Double>]
|
||||
[[-purchase_date] <DateTime>] [[-requestable] <Boolean>] [[-archived] <Boolean>] [[-rtd_location_id] <Int32>]
|
||||
[-url] <String> [-apiKey] <String> [[-customfields] <Hashtable>] [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
|
|
@ -22,25 +25,101 @@ Long description
|
|||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Set-Asset -id 1 -status_id 1 -model_id 1 -name "Machine1"
|
||||
```
|
||||
|
||||
### -------------------------- EXAMPLE 2 --------------------------
|
||||
### EXAMPLE 2
|
||||
```
|
||||
Set-Asset -id 1 -status_id 1 -model_id 1 -name "Machine1" -CustomValues = @{ "_snipeit_os_5 = "Windows 10 Pro" }
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 17
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -archived
|
||||
Whether or not the asset is archived.
|
||||
Archived assets cannot be checked out and do not show up in the deployable asset screens
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 14
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -assigned_to
|
||||
The id of the user the asset is currently checked out to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
The id of an associated company id
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -customfields
|
||||
Hastable of custom fields and extra fields that need passing through to Snipeit
|
||||
|
||||
```yaml
|
||||
Type: Hashtable
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 18
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
ID of the Asset
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
|
|
@ -49,31 +128,16 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Name
|
||||
Name of the Asset
|
||||
### -last_checkout
|
||||
Date the asset was last checked out
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Status_id
|
||||
Status ID of the asset, this can be got using Get-Status
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -85,55 +149,175 @@ Model ID of the asset, this can be got using Get-Model
|
|||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Name
|
||||
Asset name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
Order number for the asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_cost
|
||||
Purchase cost of the asset, without a currency symbol
|
||||
|
||||
```yaml
|
||||
Type: Double
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Date of asset purchase
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -requestable
|
||||
Whether or not the asset can be requested by users with the permission to request assets
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -rtd_location_id
|
||||
The id that corresponds to the location where the asset is usually located when not checked out
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 15
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -serial
|
||||
Serial number of the asset
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Status_id
|
||||
Status ID of the asset, this can be got using Get-Status
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 5
|
||||
Position: 16
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
### -warranty_months
|
||||
Number of months for the asset warranty
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -customfields
|
||||
Hastable of custom fields and extra fields that need passing through to Snipeit
|
||||
|
||||
```yaml
|
||||
Type: Hashtable
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Position: 10
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -155,23 +339,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -180,4 +349,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,36 +1,173 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-AssetOwner
|
||||
|
||||
## SYNOPSIS
|
||||
{{Fill in the Synopsis}}
|
||||
Checkout asset
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-AssetOwner [-id] <Int32> [-assigned_id] <Int32> [[-checkout_to_type] <String>] [-url] <String>
|
||||
Set-AssetOwner [-id] <Int32> [-assigned_id] <Int32> [[-checkout_to_type] <String>] [[-name] <String>]
|
||||
[[-note] <String>] [[-expected_checkin] <DateTime>] [[-checkout_at] <DateTime>] [-url] <String>
|
||||
[-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
Checkout asset to user/localtion/asset
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### Example 1
|
||||
### EXAMPLE 1
|
||||
```
|
||||
PS C:\> {{ Add example code here }}
|
||||
Remove-User -ID 44 -url $url -apiKey $secret -Verbose
|
||||
```
|
||||
|
||||
{{ Add example description here }}
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -assigned_id
|
||||
Id of target user , location or asset
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -checkout_at
|
||||
Optional date to override the checkout time of now
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -checkout_to_type
|
||||
{{ Fill checkout_to_type Description }}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: User
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -expected_checkin
|
||||
Optional date the asset is expected to be checked in
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
Unique ID For asset to checkout
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Optional new asset name.
|
||||
This is useful for changing the asset's name on new checkout,
|
||||
for example, an asset that was named "Anna's Macbook Pro" could be renamed on the fly
|
||||
when it's checked out to Elizabeth, to "Beth's Macbook Pro"
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -note
|
||||
Notes about checkout
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
|
|
@ -62,94 +199,13 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
{{Fill apiKey Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -assigned_id
|
||||
{{Fill assigned_id Description}}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -checkout_to_type
|
||||
{{Fill checkout_to_type Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Accepted values: location, asset, user
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
{{Fill id Description}}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 0
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
{{Fill url Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
### None
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
### System.Object
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,36 +1,170 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-Component
|
||||
|
||||
## SYNOPSIS
|
||||
{{Fill in the Synopsis}}
|
||||
Updates component
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-Component [-id] <String> [-qty] <String> [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm]
|
||||
[<CommonParameters>]
|
||||
Set-Component [-id] <String> [-qty] <String> [[-name] <String>] [[-company_id] <Int32>]
|
||||
[[-location_id] <Int32>] [[-purchase_date] <DateTime>] [[-purchase_cost] <Single>] [-url] <String>
|
||||
[-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
Updates component on Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### Example 1
|
||||
### EXAMPLE 1
|
||||
```
|
||||
PS C:\> {{ Add example code here }}
|
||||
An example
|
||||
```
|
||||
|
||||
{{ Add example description here }}
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
{{ Fill company_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
ID number of name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
ID number of the location the accessory is assigned to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Component name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_cost
|
||||
Cost of item being purchased.
|
||||
|
||||
```yaml
|
||||
Type: Single
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Date accessory was purchased
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -qty
|
||||
Quantity of the components you have
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
|
|
@ -62,78 +196,14 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
{{Fill apiKey Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
{{Fill id Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 0
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -qty
|
||||
{{Fill qty Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
{{Fill url Description}}
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
### None
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
### System.Object
|
||||
|
||||
## NOTES
|
||||
General notes
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
|
|
@ -1,14 +1,14 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-Info
|
||||
|
||||
## SYNOPSIS
|
||||
{{Fill in the Synopsis}}
|
||||
Sets authetication information
|
||||
|
||||
## SYNTAX
|
||||
|
||||
|
|
@ -17,26 +17,39 @@ Set-Info [[-url] <Uri>] [[-apiKey] <String>] [<CommonParameters>]
|
|||
```
|
||||
|
||||
## DESCRIPTION
|
||||
{{Fill in the Description}}
|
||||
Set apikey and url user to connect Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### Example 1
|
||||
### EXAMPLE 1
|
||||
```
|
||||
PS C:\> {{ Add example code here }}
|
||||
Set-Info -url $url -apiKey -Verbose
|
||||
```
|
||||
|
||||
{{ Add example description here }}
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
{{Fill apiKey Description}}
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: Uri
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 1
|
||||
|
|
@ -45,33 +58,13 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
{{Fill url Description}}
|
||||
|
||||
```yaml
|
||||
Type: Uri
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 0
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
### None
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
### System.Object
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
376
docs/Set-License.md
Normal file
376
docs/Set-License.md
Normal file
|
|
@ -0,0 +1,376 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-License
|
||||
|
||||
## SYNOPSIS
|
||||
Updates a licence
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-License [-id] <Int32> [[-name] <String>] [[-seats] <Int32>] [[-category_id] <Int32>]
|
||||
[[-company_id] <Int32>] [[-expiration_date] <DateTime>] [[-license_email] <MailAddress>]
|
||||
[[-license_name] <String>] [[-maintained] <Boolean>] [[-manufacturer_id] <Int32>] [[-notes] <String>]
|
||||
[[-order_number] <String>] [[-purchase_cost] <Single>] [[-purchase_date] <DateTime>]
|
||||
[[-reassignable] <Boolean>] [[-serial] <String>] [[-supplier_id] <Int32>] [[-termination_date] <DateTime>]
|
||||
[-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Updates licence on Snipe-It system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Set-Licence -name "License" -seats 3 -company_id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 20
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
{{ Fill category_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
Id number of company license belongs to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -expiration_date
|
||||
Date of license expiration
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
ID number of licence
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -license_email
|
||||
Email address associated with license
|
||||
|
||||
```yaml
|
||||
Type: MailAddress
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -license_name
|
||||
Name of license contact person
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -maintained
|
||||
Maintained status of license
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
ID number of manufacturer of license.
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of license
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
License Notes
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -order_number
|
||||
Order number of license purchase
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_cost
|
||||
Cost of license
|
||||
|
||||
```yaml
|
||||
Type: Single
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -purchase_date
|
||||
Date of license purchase
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 14
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -reassignable
|
||||
Is license reassignable?
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 15
|
||||
Default value: False
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -seats
|
||||
Number of license seats owned.
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -serial
|
||||
Serialnumber of license
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 16
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -supplier_id
|
||||
ID number of license supplier
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 17
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -termination_date
|
||||
Termination date for license.
|
||||
|
||||
```yaml
|
||||
Type: DateTime
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 18
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 19
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
208
docs/Set-Model.md
Normal file
208
docs/Set-Model.md
Normal file
|
|
@ -0,0 +1,208 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-Model
|
||||
|
||||
## SYNOPSIS
|
||||
Updates Model on Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-Model [-id] <Int32> [[-name] <String>] [[-model_number] <String>] [[-category_id] <Int32>]
|
||||
[[-manufacturer_id] <Int32>] [[-eol] <Int32>] [[-custom_fieldset_id] <Int32>] [-url] <String>
|
||||
[-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Updates Model on Snipe-it asset system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
New-Model -name "DL380" -manufacturer_id 2 -fieldset_id 2 -category_id 1
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -category_id
|
||||
Category ID that the asset belongs to this can be got using Get-Category
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -custom_fieldset_id
|
||||
{{ Fill custom_fieldset_id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases: fieldset_id
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -eol
|
||||
{{ Fill eol Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
ID number of the Asset Model
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manufacturer_id
|
||||
Manufacturer ID that the asset belongs to this can be got using Get-Manufacturer
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -model_number
|
||||
Model number of the Asset Model
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of the Asset Model
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 8
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
253
docs/Set-SnipeitLocation.md
Normal file
253
docs/Set-SnipeitLocation.md
Normal file
|
|
@ -0,0 +1,253 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-SnipeitLocation
|
||||
|
||||
## SYNOPSIS
|
||||
Updates Location in Snipe-it asset system
|
||||
|
||||
## SYNTAX
|
||||
|
||||
```
|
||||
Set-SnipeitLocation [-id] <Int32> [[-name] <String>] [[-address] <String>] [[-address2] <String>]
|
||||
[[-state] <String>] [[-country] <String>] [[-zip] <String>] [[-manager_id] <Int32>] [[-ldap_ou] <String>]
|
||||
[[-parent_id] <Int32>] [-url] <String> [-apiKey] <String> [-WhatIf] [-Confirm] [<CommonParameters>]
|
||||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### EXAMPLE 1
|
||||
```
|
||||
Set-SnipeitLocation -id 123 -name "Some storage" -parent_id 100
|
||||
```
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -address
|
||||
Address line 1
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -address2
|
||||
Address line 2
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Users API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -country
|
||||
Address Contry
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
{{ Fill id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -ldap_ou
|
||||
LDAP OU of Location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
Location manager as id
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -name
|
||||
Name of Location
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -parent_id
|
||||
Parent location as id
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -state
|
||||
Address State
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 11
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -zip
|
||||
Address zipcode
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
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.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: wi
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
## OUTPUTS
|
||||
|
||||
## NOTES
|
||||
|
||||
## RELATED LINKS
|
||||
433
docs/Set-User.md
433
docs/Set-User.md
|
|
@ -1,14 +1,14 @@
|
|||
---
|
||||
external help file: SnipeItPS-help.xml
|
||||
Module Name: SnipeItPS
|
||||
online version: http://go.microsoft.com/fwlink/?LinkId=821589
|
||||
Module Name: SnipeitPS
|
||||
online version:
|
||||
schema: 2.0.0
|
||||
---
|
||||
|
||||
# Set-User
|
||||
|
||||
## SYNOPSIS
|
||||
Short description
|
||||
Creates a new user
|
||||
|
||||
## SYNTAX
|
||||
|
||||
|
|
@ -21,204 +21,26 @@ Set-User [-id] <Int32> [[-first_name] <String>] [[-last_name] <String>] [[-userN
|
|||
```
|
||||
|
||||
## DESCRIPTION
|
||||
Long description
|
||||
Creates a new user to Snipe-IT system
|
||||
|
||||
## EXAMPLES
|
||||
|
||||
### -------------------------- EXAMPLE 1 --------------------------
|
||||
### EXAMPLE 1
|
||||
```
|
||||
An example
|
||||
Update-user -id 3 -fist_name It -lastname Snipe -username snipeit -activated $false -company_id 1 -location_id 1 -department_id 1
|
||||
```
|
||||
|
||||
Updates user with id 3
|
||||
|
||||
## PARAMETERS
|
||||
|
||||
### -id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -first_name
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -last_name
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -userName
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -jobtitle
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -email
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -phone
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -department_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -employee_num
|
||||
Parameter description
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -activated
|
||||
Parameter description
|
||||
{{ Fill activated Description }}
|
||||
|
||||
```yaml
|
||||
Type: Boolean
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 13
|
||||
|
|
@ -227,13 +49,178 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
Parameter description
|
||||
### -apiKey
|
||||
User's API Key for Snipeit, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 16
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -company_id
|
||||
ID number of company users belogs to
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 8
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -department_id
|
||||
ID number of department
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 10
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -email
|
||||
email address
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 6
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -employee_num
|
||||
Employeenumber
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 12
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -first_name
|
||||
Users first name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 2
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -id
|
||||
{{ Fill id Description }}
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 1
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -jobtitle
|
||||
Users job tittle
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 5
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -last_name
|
||||
Users last name
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 3
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -location_id
|
||||
ID number of localtion
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 9
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -manager_id
|
||||
ID number of manager
|
||||
|
||||
```yaml
|
||||
Type: Int32
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 11
|
||||
Default value: 0
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -notes
|
||||
User Notes
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 14
|
||||
|
|
@ -242,13 +229,28 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
Parameter description
|
||||
### -phone
|
||||
Phone number
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: False
|
||||
Position: 7
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -url
|
||||
URL of Snipeit system, can be set using Set-Info command
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 15
|
||||
|
|
@ -257,16 +259,31 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -apiKey
|
||||
Parameter description
|
||||
### -userName
|
||||
Username for user
|
||||
|
||||
```yaml
|
||||
Type: String
|
||||
Parameter Sets: (All)
|
||||
Aliases:
|
||||
Aliases:
|
||||
|
||||
Required: True
|
||||
Position: 16
|
||||
Required: False
|
||||
Position: 4
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
|
|
@ -288,23 +305,8 @@ Accept pipeline input: False
|
|||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### -Confirm
|
||||
Prompts you for confirmation before running the cmdlet.
|
||||
|
||||
```yaml
|
||||
Type: SwitchParameter
|
||||
Parameter Sets: (All)
|
||||
Aliases: cf
|
||||
|
||||
Required: False
|
||||
Position: Named
|
||||
Default value: None
|
||||
Accept pipeline input: False
|
||||
Accept wildcard characters: False
|
||||
```
|
||||
|
||||
### CommonParameters
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
||||
|
||||
## INPUTS
|
||||
|
||||
|
|
@ -314,4 +316,3 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable
|
|||
General notes
|
||||
|
||||
## RELATED LINKS
|
||||
|
||||
|
|
|
|||
115
docs/SnipeItPS.md
Normal file
115
docs/SnipeItPS.md
Normal file
|
|
@ -0,0 +1,115 @@
|
|||
---
|
||||
Module Name: SnipeitPS
|
||||
Module Guid: {{ Update Module Guid }}
|
||||
Download Help Link: {{ Update Download Link }}
|
||||
Help Version: {{ Update Help Version }}
|
||||
Locale: {{ Update Locale }}
|
||||
---
|
||||
|
||||
# SnipeitPS Module
|
||||
## Description
|
||||
{{ Fill in the Description }}
|
||||
|
||||
## SnipeitPS Cmdlets
|
||||
### [Get-Accessory](Get-Accessory.md)
|
||||
Gets a list of Snipe-it Accessories
|
||||
|
||||
### [Get-Asset](Get-Asset.md)
|
||||
Gets a list of Snipe-it Assets or specific asset
|
||||
|
||||
### [Get-AssetMaintenance](Get-AssetMaintenance.md)
|
||||
Lists Snipe-it Assets Maintenances
|
||||
|
||||
### [Get-Category](Get-Category.md)
|
||||
Gets a list of Snipe-it Categories
|
||||
|
||||
### [Get-Company](Get-Company.md)
|
||||
Gets a list of Snipe-it Companies
|
||||
|
||||
### [Get-Component](Get-Component.md)
|
||||
Gets a list of Snipe-it Components
|
||||
|
||||
### [Get-CustomField](Get-CustomField.md)
|
||||
Returns a list of all Snipe-IT custom fields
|
||||
|
||||
### [Get-Department](Get-Department.md)
|
||||
Gets a list of Snipe-it Departments
|
||||
|
||||
### [Get-Fieldset](Get-Fieldset.md)
|
||||
Gets a list of Snipe-it Fieldsets
|
||||
|
||||
### [Get-Model](Get-Model.md)
|
||||
Gets a list of Snipe-it Models
|
||||
|
||||
### [Get-SnipeitLocation](Get-SnipeitLocation.md)
|
||||
Gets a list of Snipe-it Locations
|
||||
|
||||
### [Get-Status](Get-Status.md)
|
||||
Gets a list of Snipe-it Status Labels
|
||||
|
||||
### [New-Asset](New-Asset.md)
|
||||
Add a new Asset to Snipe-it asset system
|
||||
|
||||
### [New-AssetMaintenance](New-AssetMaintenance.md)
|
||||
Add a new Asset maintenence to Snipe-it asset system
|
||||
|
||||
### [New-Category](New-Category.md)
|
||||
Create a new Snipe-IT Category
|
||||
|
||||
### [New-Component](New-Component.md)
|
||||
Create a new component
|
||||
|
||||
### [New-CustomField](New-CustomField.md)
|
||||
Add a new Custom Field to Snipe-it asset system
|
||||
|
||||
### [New-Department](New-Department.md)
|
||||
Creates a department
|
||||
|
||||
### [New-License](New-License.md)
|
||||
Creates a licence
|
||||
|
||||
### [New-Location](New-Location.md)
|
||||
Add a new Location to Snipe-it asset system
|
||||
|
||||
### [New-Manufacturer](New-Manufacturer.md)
|
||||
Add a new Manufacturer to Snipe-it asset system
|
||||
|
||||
### [New-Model](New-Model.md)
|
||||
Add a new Model to Snipe-it asset system
|
||||
|
||||
### [New-User](New-User.md)
|
||||
Creates a new user
|
||||
|
||||
### [Remove-Asset](Remove-Asset.md)
|
||||
Removes Asset to Snipe-it asset system
|
||||
|
||||
### [Remove-User](Remove-User.md)
|
||||
Removes User from Snipe-it asset system
|
||||
|
||||
### [Set-Accessory](Set-Accessory.md)
|
||||
Updates accessory on Snipe-It system
|
||||
|
||||
### [Set-Asset](Set-Asset.md)
|
||||
Update a specific Asset in the Snipe-it asset system
|
||||
|
||||
### [Set-AssetOwner](Set-AssetOwner.md)
|
||||
Checkout asset
|
||||
|
||||
### [Set-Component](Set-Component.md)
|
||||
Updates component
|
||||
|
||||
### [Set-Info](Set-Info.md)
|
||||
Sets authetication information
|
||||
|
||||
### [Set-License](Set-License.md)
|
||||
Updates a licence
|
||||
|
||||
### [Set-Model](Set-Model.md)
|
||||
Updates Model on Snipe-it asset system
|
||||
|
||||
### [Set-SnipeitLocation](Set-SnipeitLocation.md)
|
||||
Updates Location in Snipe-it asset system
|
||||
|
||||
### [Set-User](Set-User.md)
|
||||
Creates a new user
|
||||
|
||||
Loading…
Add table
Reference in a new issue