Goal: Output a png with red background.

Picturepark supports various modifications for rasterized images, but only limited actions for vectors, documents, or videos. Actions like alpha handling or cropping are not supported for vector images. Therefore you have to use the Rendering Chain and create a rasterized image from the vector original (or video) and then further process the rasterized temp format. There you can then apply modifications like a watermark, cropping, alpha handling, or others. 

Rendering Chain

Vector > Rasterized Temp Format > Final PNG Output

Setup Postman Environment

Ensure that the postman environment variables are set correctly. Check API clients for details. 

Variable

Value

apiToken

In the main menu find Settings. Check if you see API Clients in the settings. Create an API Client. Open Token. Create API Token. 

Otherwise request for your user to be set to "isDeveloper" with support@picturepark.com as this setting is found in the Cloud Manager.

customerAlias

In the main menu open Help and find "System Information". There you find the alias. 

customerId

In the main menu open Help and find "System Information". There you find the customer UID. 

apiHost

The form is https://api.[domain]

See your Picturepark > Settings > System Information.

Post: {{apiHost}}/v1/outputformats

Create a Vector Still Format from a Vector Original. 

{
    "id": "VectorStillForTransparency",
    "names": {
    	"en": "Vector Still Format"
    },
    "dynamic": true,
    "temporary":true,
    "format": {
    	"kind": "VectorStillFormat",
    	
    },
    "sourceOutputFormats": {
    	"vector": "Original"
    }
}
CODE

Post: {{apiHost}}/v1/outputformats/preview

Allows creating a temporary output format to test your settings and get a direct preview of this format for your content. 

Update: contentId

{
	"contentId": "xxx",
	"outputFormat": {	   
	    "sourceOutputFormats": {	        
            "vector": "VectorStillForTransparency"	        
	    },
	    "format": {
	        "kind": "PngFormat",
	        "colorProfile":"Srgb",
	        "keepClippingPath":true,
	        "resizeAction": {
	        	"resizeMode": "Fit",
	        	"width": 1920,
	        	"height": 1920
	        },
	        "actions":[
	        	{
	        		"kind":"AlphaHandlingAction",
	        		"alphaHandling":"DiscardAlpha",
	        		"replacementRgbColorHexCode":"0xffffff"
	        	}	        	
	        ]	        
	    }
	}
}
CODE

Post: {{apiHost}}/v1/outputformats

Create your format and provide the settings you tested in Step 3. 

{
    "id": "TransparentPng",
    "dynamic": true,
    "temporary":true,
    "names": {
        "en": "Transparent (png)",
        "de": "Transparent (png)"        
    },
   "sourceOutputFormats": {	        
            "vector": "VectorStillForTransparency"	        
	    },
	"format": {
		"kind": "PngFormat",
	    "colorProfile":"Srgb",
	    "keepClippingPath":true,
	    "resizeAction": {
	        	"resizeMode": "Fit",
	        	"width": 1920,
	        	"height": 1920
	    },
	    "actions":[
	     		{
	        		"kind":"AlphaHandlingAction",
	        		"alphaHandling":"DiscardAlpha",
	        		"replacementRgbColorHexCode":"0xffffff"
	        	}	        	
		]	        
	}    
}
CODE


Postman File

Create Transparent PNG from Vectors.postman_collection.json