Get-ShopifyThemeAsset #
ÜBERSICHT #
Liest ein einzelnes Theme-Asset (Liquid-Datei) aus einem Shopify-Theme.
SYNTAX #
Get-ShopifyThemeAsset [-Shop] <string> [-Token] <string> [-ApiVersion] <string> [-ThemeId] <long>
[-AssetKey] <string> [[-TimeoutSec] <int>] [<CommonParameters>]
BESCHREIBUNG #
Ruft /admin/api/{version}/themes/{id}/assets.json?asset[key]={key} ab und liefert den Dateiinhalt als String.
Gibt $null zurück wenn das Asset nicht existiert (HTTP 404).
PARAMETER #
-Shop #
Type: string
Shopify-Shop-Domain, z.B. ‘mein-shop.myshopify.com’.
-Token #
Type: string
Admin API Access Token (shpat_…) der Custom App.
-ApiVersion #
Type: string
API-Version, z.B. ‘2025-01’.
-ThemeId #
Type: long
Shopify Theme-ID.
-AssetKey #
Type: string
Pfad des Assets im Theme, z.B. ‘snippets/eulanda-order-documents.liquid’.
-TimeoutSec #
Type: int
Default: 60
HTTP Timeout in Sekunden.
AUSGABEN #
pscustomobject -- Objekt mit Key, Value (Dateiinhalt), ContentType.
$null wenn das Asset nicht existiert.
BEISPIELE #
$asset = Get-ShopifyThemeAsset -Shop 'mein-shop.myshopify.com' `
-Token 'shpat_abc123' -ApiVersion '2025-01' `
-ThemeId 123456789 -AssetKey 'snippets/eulanda-order-documents.liquid'