Server-side SDK overview

Updated at:

Download the server-side SDK source code and use the SDK to call OpenAPI operations.

Contact us

If you have questions or want to obtain technical support, join the DingTalk group for IMS (ID: 84650000851) to contact us.

SDK source code

Language

GitHub address

Java

alibabacloud-java-sdk

Python

alibabacloud-python-sdk

PHP

alibabacloud-sdk-php

Node.js

alibabacloud-typescript-sdk

Go

alibabacloud-go

Intelligent Media Services also provides SDKs for other languages, such as C# and C++. For more information, see Server-side SDKs.

How to call OpenAPI

To call OpenAPI operations by using the server-side SDK, perform the following steps:

Step

Operation

1

Activate Intelligent Media Services. For more information, see Activate a service.

2

Obtain an AccessKey pair. For more information, see Create an AccessKey.

3

Install the SDK. For more information, see Install the SDK.

4

Initialize the client. In Config, explicitly specify the IMS service access address of the target region through the endpoint, for example, China (Beijing) is ice.cn-beijing.aliyuncs.com. For the access address of each region, see Endpoints.

5

Call OpenAPI operations to implement features.

Important
  • Be sure to set the endpoint when initializing the client. When only regionId is set, the request cannot be routed to the target region, and errors such as ServiceUnavailable(503) are returned. Example is as follows:

    from alibabacloud_ice20201109.client import Client as ICE20201109Client
    from alibabacloud_credentials.client import Client as CredClient
    from alibabacloud_tea_openapi.models import Config
    
    cred = CredClient()
    config = Config(credential=cred)
    # Explicitly specify the IMS service access address, for example, North China 2 (Beijing)
    config.endpoint = 'ice.cn-beijing.aliyuncs.com'
    client = ICE20201109Client(config)
  • The region of the endpoint must be the same as the region where the input and output OSS buckets are located, and the functions are available in this region. When you call a VPC in the same region, you can use the VPC access address, for example, ice-vpc.cn-beijing.aliyuncs.com.

  • The IMS access address (ice.<region ID>.aliyuncs.com) and the OSS Endpoint(oss-<region ID>.aliyuncs.com) are two different addresses and cannot be replaced by each other.