All Documents
Current Document

Content is empty

If you don't find the content you expect, please try another search term

Documentation

Pipeline

Last updated:2021-11-02 17:53:48

Operation

None

Description

The image processing features of KS3 enable you to use the pipeline to perform multiple operations on images to meet your requirements in complex scenarios. The pipeline enables you to use the vertical bar (|) to connect different operations.

Permission

To use the pipeline, you must have the GetObject permission. If the object does not exist, the following errors may be returned:

  • If you have the ListBucket permission on the bucket where the object resides, KS3 returns a 404 error.
  • If you do not have the ListBucket permission on the bucket, KS3 returns a 403 error.

Sample request

Resize an image and add two watermarks to it

  • Style 1
    • The width is 200 pixels, and the height is 150 pixels.
  • Style 2
    • Watermark URL: https://ks3-cn-beijing.ksyuncs.com/ks3-resources/fixed_ksc_logo.png
    • Watermark position: upper-right corner
      • gravity=NorthEast
    • Watermark opacity: 65%
      • dissolve=65
    • Horizontal distance between the right edges of the watermark and the image: 10
      • dx=10
    • Vertical distance between the bottom edges of the watermark and the image: 10
      • dy=10
  • Style 3
    • Watermark URL: https://ks3-resources.ks3-cn-beijing.ksyuncs.com/fixed_ksc_logo.png
    • Watermark position: lower-right corner
      • gravity=SouthEast
    • Watermark opacity: 65%
      • dissolve=65
    • Horizontal distance between the right edges of the watermark and the image: 10
      • dx=10
    • Vertical distance between the bottom edges of the watermark and the image: 10
      • dy=10

Request code

Note: The request code does not contain spaces or line breaks. The following code format is only for easy reading.

https://ks3-resources.ks3-cn-beijing.ksyuncs.com/suiyi.jpg@base@
    tag=imgBaseOp   
    &mode=0   
    &h=160   
    &w=220   
    |tag=imgWaterMark   
    &type=1   
    &dissolve=65   
    &gravity=NorthEast   
    &image=aHR0cDovL2tzMy5rc3l1bi5jb20vY3NzL2ltZy9maXhlZF9rc2NfbG9nby5wbmc=   
    &dy=10   
    &dx=10
    |tag=imgWaterMark   
    &type=1   
    &dissolve=65   
    &gravity=SouthEast   
    &image=aHR0cDovL2tzMy5rc3l1bi5jb20vY3NzL2ltZy9maXhlZF9rc2NfbG9nby5wbmc=   
    &dy=10   
    &dx=10   

Sample response

Pipeline file

On this page
Pure ModeNormal Mode

Pure Mode

Click to preview the document content in full screen
Feedback