v2.video.delete_video
POST /api/v2/video/delete_video
Use this API to delete video. You can delete the video for both draft and post status.
Đường dẫn Endpoint
URL: https://partner.shopeemobile.com/api/v2/video/delete_video
Tham số chung
| Tên | Kiểu | Mẫu | Mô tả |
|---|---|---|---|
| partner_id | int | 1 | Partner ID được gán khi đăng ký thành công. Bắt buộc cho tất cả các yêu cầu. |
| timestamp | timestamp | 1610000000 | Dùng để chỉ định thời gian của yêu cầu. Bắt buộc cho tất cả các yêu cầu. Hết hạn sau 5 phút. |
| access_token | string | c09222e3fc40ffb25fc947f738b1abf1 | Token truy cập API, dùng để xác định quyền của bạn đối với API. Có thể sử dụng nhiều lần và hết hạn sau 4 giờ. |
| user_id | int | 1 | Shopee's mã định danh duy nhất for a user. |
| sign | string | e318d3e932719916a9f9ebb57e2011961bd47abfa54a36e040d050d8931596e2 | Signature generated by(depends on different APIs) partner_id, api path, timestamp, access_token, user_id and partner_key via HMAC-SHA256 hashing algorithm. |
Tham số Request
| Tên | Kiểu | Bắt buộc | Mẫu | Mô tả |
|---|---|---|---|---|
| video_upload_id_list | string[] | False | ["sg-11110199-6v8gq-mgbni6rb44qz04"] | You can only select one from video_upload_id_list and post_id_list: - If you want to delete video with draft status, please pass video_upload_id_list. - If you want to delete video with post status, please pass post_id_list. |
| post_id_list | string[] | False | ["YwOo_gZqCACXbM0UAAAAAA=="] | You can only select one from video_upload_id_list and post_id_list: - If you want to delete video with draft status, please pass video_upload_id_list. - If you want to delete video with post status, please pass post_id_list. |
Tham số Response
| Tên | Kiểu | Mẫu | Mô tả |
|---|---|---|---|
| error | string | Loại lỗi nếu có lỗi xảy ra. Trống nếu không có lỗi. | |
| message | string | Chi tiết lỗi nếu có lỗi xảy ra. Trống nếu không có lỗi. | |
| request_id | string | 2af852cd-7420-4714-b7cd-33317f6fe548 | Mã định danh của yêu cầu API dùng để theo dõi lỗi. |
| response | object | Detail informations you are querying. | |
| success_list | object[] | The danh sách video delete successfully. | |
| success_video_upload_id | string | The video_upload_id delete successfully. | |
| success_post_id | string | The post_id delete successfully. | |
| failure_list | object[] | The danh sách video delete deleted. | |
| fail_video_upload_id | string | Failed video_upload_id. | |
| fail_post_id | string | Failed post_id. | |
| failed_reason | string | Failed reason of the corresponding video_upload_id or post_id. |
Dữ liệu gửi
Unirest.setTimeouts(0, 0);
HttpResponse<String> response = Unirest.post("https://partner.shopeemobile.com/api/v2/video/delete\_video?access\_token=access\_token&partner\_id=partner\_id&sign=sign×tamp=timestamp&user\_id=user\_id")
.header("Content-Type","application/json")
.body("{
"post_id_list": [
"YwOo_gZqCACXbM0UAAAAAA=="
],
"video_upload_id_list": [
"sg-11110199-6v8gq-mgbni6rb44qz04"
]
}")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://partner.shopeemobile.com/api/v2/video/delete\_video?access\_token=access\_token&partner\_id=partner\_id&sign=sign×tamp=timestamp&user\_id=user\_id',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS => '{
"post_id_list": [
"YwOo_gZqCACXbM0UAAAAAA=="
],
"video_upload_id_list": [
"sg-11110199-6v8gq-mgbni6rb44qz04"
]
}',
CURLOPT_HTTPHEADER => array(
'Content-Type: application/json'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
curl --location --request POST 'https://partner.shopeemobile.com/api/v2/video/delete\_video?access\_token=access\_token&partner\_id=partner\_id&sign=sign×tamp=timestamp&user\_id=user\_id'
--header 'Content-Type: application/json'
--data-raw '{
"post_id_list": [
"YwOo_gZqCACXbM0UAAAAAA=="
],
"video_upload_id_list": [
"sg-11110199-6v8gq-mgbni6rb44qz04"
]
}'
import requests
import json
url = "https://partner.shopeemobile.com/api/v2/video/delete\_video?access\_token=access\_token&partner\_id=partner\_id&sign=sign×tamp=timestamp&user\_id=user\_id"
payload=json.dumps({
"post_id_list": [
"YwOo_gZqCACXbM0UAAAAAA=="
],
"video_upload_id_list": [
"sg-11110199-6v8gq-mgbni6rb44qz04"
]
})
headers = {
'Content-Type': 'application/json'
}
response = requests.RPCRequest("POST",url,headers=headers, data=payload, allow_redirects=False)
print(response.text)
], "failure_list": [] }, "request_id": "63d15f2f-018d-4581-9b25-b67aff42c688" }
] }, "request_id": "d62eec3e-f104-4235-9430-2db399cdfd3e" }