All Products
Search
Document Center

GetWatermark

Last Updated: Jul 11, 2019

Description

You can call this operation to query a watermark.

Request parameters

Parameter Type Required Description
Action String Yes The operation that you want to perform. Set this parameter to GetWatermark.
WatermarkId String Yes The ID of the watermark.

Response parameters

Parameter Type Description
RequestId String The ID of the request.
WatermarkInfo WatermarkInfo The watermark information.

API examples

Sample request

https://vod.cn-shanghai.aliyuncs.com?Action=GetWatermark&WatermarkId=9bcc8bfadb843f475c109a2671d0df97

Sample response

JSON format

  • Text watermark
{
    "RequestId": "25818875-5F78-4A13-BEF6-D7393642CA58",
      "WatermarkInfo": {
          "Name": "Text watermark test",
          "CreationTime": "2018-11-07T09:05:52Z",
          "IsDefault": "NotDefault",
          "Type": "Text",
          "WatermarkId": "9bcc8bfadb843f475c109a2671d0df97",
          "WatermarkConfig": {
            "FontColor": "Blue",
            "FontSize": 80,
            "Content": "Watermark test"
          }
      }
 }
  • Image watermark
{
   "RequestId": "25818875-5F78-4A13-BEF6-D7393642CA58",
   "WatermarkInfo":{
      "Name": "Image watermark test",
      "CreationTime": "2018-11-06T08:03:17Z",
      "WatermarkId": "505e2e287ea49c40f8cecfddd386d384",
      "FileUrl": "https://outin-3262681cdde1189f4b3e7.oss-cn-shanghai.aliyuncs.com/image/cover/F85529C8B715E6F8A72EC6B-6-2.png?Expires=1541600583&OSSAccessKeyId=XXXXXX&Signature=gmf1eYMoDVg%2BHQCb4UGozBW4xZo%3D",
      "IsDefault": "NotDefault",
      "Type": "Image",
      "WatermarkConfig": {
        "ReferPos": "BottomRight",
        "Height": "55",
        "Width": "55",
        "Dx": "8",
        "Dy": "8"
      }
    }
  }

Error codes

This operation also returns common errors. For more information about errors common to all operations, see common errors.

Error code Error message HTTP status code Description
NoSuchResource The specified resource %s does not exist. 404 The error message returned because the user-related resource data does not exist, where %s indicates the specific resource information.

SDK examples

We recommend that you use a server SDK to call this operation. For more information about the sample code used to call this operation in various languages, see the following topics: