Clone
1
Zmiana pola wyszukiwania (search-term)
Kacper Żbikowski edited this page 2026-04-02 14:09:08 +02:00
This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

Pole wyszukiwania określa, jak agent identyfikuje asset w Snipe-IT.

Znajduje się w config.json:

"search-term": {
  "type": "serial",
  "value": "(Get-CimInstance Win32_BIOS).SerialNumber"
}

Parametry:

  • type typ wyszukiwania w Snipe-IT (np. serial, asset_tag, inne wspierane przez API)

  • value komenda PowerShell zwracająca wartość

Przykłady:

Serial BIOS:

(Get-CimInstance Win32_BIOS).SerialNumber

Hostname:

$env:COMPUTERNAME

Custom (np. TeamViewer ID):

(Get-ItemProperty 'HKLM:\SOFTWARE\TeamViewer').ClientID