PSImmich
This project has adopted the following policies
Project status
Immich 3.4 API compatibility is being assessed; generated route references alone do not establish cmdlet or contract coverage. See the upgrade assessment.
About
PSImmich is a Powershell API wrapper for Immich
Installation
PowerShell Gallery
To install from the PowerShell gallery using PowerShellGet run the following command:
Install-Module PSImmich -Scope CurrentUser
Usage
Before calling the Immich cmdlets a session needs to be created. Currently it is supported to use an API key or credentials (username and password)
Connect-Immich -BaseURL 'https://immich.domain.com' -AccessToken 'ztKkvGWVIacJATX7RLCbWCISpamwEQkLpakn8O48acE'
$Cred = Get-Credential
Connect-Immich -BaseURL 'https://immich.domain.com' -Credential $Cred
You can verify that the connection is working by calling Get-IMSession and verifying that AccessTokenValid is true
Get-IMSession
BaseUri : https://immich.domain.com
AuthMethod : AccessToken
AccessToken : System.Security.SecureString
AccessTokenValid : True
Credential :
JWT :
APIUri : https://immich.domain.com/api
ImmichVersion : 1.98.2
SessionID : 67055f46-51aa-42a2-8471-46170c441558
The session object can be passed to all cmdlets. This is useful if connection to more than one Immich instance is needed.
$Session1 = Connect-Immich -BaseURL 'https://immich.domain.com' -AccessToken 'ztKkvGWVIacJATX7RLCbWCISpamwEQkLpakn8O48acE' -PassThru
Get-IMAsset -Session $Session1
To see available cmdlets you can use the following command
Get-Command -Module PSImmich | Format-Wide -Column 4 -Property Name
Add-IMActivity Add-IMAlbumAsset Add-IMAlbumUser Add-IMAsset
Add-IMAssetTag Add-IMMyProfilePicture Add-IMPartner Add-IMSharedLinkAsset
...
...
Available commands
For documentation about each command please see the docs
Passkeys
On Immich 3.4, Get-IMPasskey, Rename-IMPasskey and Remove-IMPasskey
manage the current user's existing passkeys. The corresponding API-key
permissions are passkey.read, passkey.update and passkey.delete.
Registration and sign-in using an authenticator are not yet supported.
Deleting a passkey can prevent sign-in; keep another authentication method
available.
Versioning
PSImmich follows Immich's versioning scheme to indicate compatibility:
- Major.Minor versions match Immich - PSImmich 2.3.x is developed and tested against Immich 2.3.x
- Patch version starts with Immich's patch number - If Immich releases 2.3.1, PSImmich starts at 2.3.1
- Subsequent PSImmich releases increment the patch - Additional PSImmich updates become 2.3.2, 2.3.3, etc. until the next Immich version is released.
This ensures you can easily identify which Immich version is supported by checking the first two version numbers.