Getting Started
The token obtained on IAM is valid for only 24 hours. If you want to use one token for authentication, you can cache it to avoid frequent calling.
Involved APIs
If you use a token for authentication, you must obtain the token and add X-Auth-Token to the request header of the API when making an API call.
- API for obtaining tokens from IAM
- API for creating a DIS stream
Procedure
- Obtain the token by following instructions in Token-based Authentication.
- Send POST https://Endpoint of DIS/v2/{project_id}/streams.
- Add X-Auth-Token to the request header.
- Specify the following parameters in the request body:
{ "stream_name": "dis-DLpR", "partition_count": 1, "stream_type": "COMMON", "data_type": "BLOB", "data_duration": 24 }If the request is successful, 201 Created is returned.
If the request fails, an error code and error information are returned. For details, see section Error Codes.
Last Article: Signature Process
Next Article: API Description
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.