新增快手平台和对应的接口
This commit is contained in:
@@ -40,13 +40,15 @@ INSERT INTO api_datasource_platform (
|
||||
-- =============================================
|
||||
|
||||
-- 2.1 账户关系接口(先获取所有账户ID)
|
||||
-- 出参:{"code":0, "message":"ok", "data":{"list":[...], "page_info":{...}}}
|
||||
-- 列表路径:data.list,分页:data.page_info.total_page
|
||||
INSERT INTO api_interface (
|
||||
tenant_id, creator, created_at, updater, updated_at,
|
||||
platform_id, name, code, url, method, status, auth_type,
|
||||
request_config, table_definition
|
||||
request_config, response_config, table_definition
|
||||
) VALUES (
|
||||
1, 'admin', NOW(), 'admin', NOW(),
|
||||
1,
|
||||
(SELECT id FROM api_datasource_platform WHERE platform_code = 'tencent'),
|
||||
'账户列表', 'account_relation',
|
||||
'/advertiser/get', 'GET', 'active', 'inherit',
|
||||
'{
|
||||
@@ -58,6 +60,12 @@ INSERT INTO api_interface (
|
||||
"pagination_mode": "PAGINATION_MODE_NORMAL",
|
||||
"fields": ["account_id", "corporation_name", "is_adx", "is_bid", "is_mp"]
|
||||
}'::jsonb,
|
||||
'{
|
||||
"success_field": "code",
|
||||
"success_value": 0,
|
||||
"message_field": "message",
|
||||
"list_path": "data.list"
|
||||
}'::jsonb,
|
||||
'{
|
||||
"table_name": "tencent_account_relation",
|
||||
"columns": [
|
||||
@@ -72,13 +80,15 @@ INSERT INTO api_interface (
|
||||
);
|
||||
|
||||
-- 2.2 图片素材接口(遍历每个账户拉取图片)
|
||||
-- 出参:{"code":0, "message":"ok", "data":{"list":[...], "page_info":{...}}}
|
||||
-- 列表路径:data.list,分页:data.page_info.total_page
|
||||
INSERT INTO api_interface (
|
||||
tenant_id, creator, created_at, updater, updated_at,
|
||||
platform_id, name, code, url, method, status, auth_type,
|
||||
request_config, table_definition
|
||||
request_config, response_config, table_definition
|
||||
) VALUES (
|
||||
1, 'admin', NOW(), 'admin', NOW(),
|
||||
1,
|
||||
(SELECT id FROM api_datasource_platform WHERE platform_code = 'tencent'),
|
||||
'图片素材', 'image',
|
||||
'/images/get', 'GET', 'active', 'inherit',
|
||||
'{
|
||||
@@ -96,6 +106,12 @@ INSERT INTO api_interface (
|
||||
"value_field": "account_id"
|
||||
}
|
||||
}'::jsonb,
|
||||
'{
|
||||
"success_field": "code",
|
||||
"success_value": 0,
|
||||
"message_field": "message",
|
||||
"list_path": "data.list"
|
||||
}'::jsonb,
|
||||
'{
|
||||
"table_name": "tencent_image",
|
||||
"columns": [
|
||||
@@ -120,7 +136,7 @@ INSERT INTO api_interface (
|
||||
{"name": "quality_status", "type": "VARCHAR(50)", "comment": "质量状态"},
|
||||
{"name": "aigc_flag", "type": "VARCHAR(50)", "comment": "AIGC标志"},
|
||||
{"name": "aigc_type", "type": "INT", "comment": "AIGC类型"},
|
||||
{"name": "verify_status", "type": "VARCHAR(50) DEFAULT 'PENDING'", "comment": "校验状态"},
|
||||
{"name": "verify_status", "type": "VARCHAR(50)", "comment": "校验状态"},
|
||||
{"name": "verified_at", "type": "TIMESTAMP WITH TIME ZONE", "comment": "校验时间"},
|
||||
{"name": "verified_by", "type": "VARCHAR(64)", "comment": "校验人"}
|
||||
],
|
||||
@@ -129,13 +145,15 @@ INSERT INTO api_interface (
|
||||
);
|
||||
|
||||
-- 2.3 视频素材接口(遍历每个账户拉取视频)
|
||||
-- 出参:{"code":0, "message":"ok", "data":{"list":[...], "page_info":{...}}}
|
||||
-- 列表路径:data.list,分页:data.page_info.total_page
|
||||
INSERT INTO api_interface (
|
||||
tenant_id, creator, created_at, updater, updated_at,
|
||||
platform_id, name, code, url, method, status, auth_type,
|
||||
request_config, table_definition
|
||||
request_config, response_config, table_definition
|
||||
) VALUES (
|
||||
1, 'admin', NOW(), 'admin', NOW(),
|
||||
1,
|
||||
(SELECT id FROM api_datasource_platform WHERE platform_code = 'tencent'),
|
||||
'视频素材', 'video',
|
||||
'/videos/get', 'GET', 'active', 'inherit',
|
||||
'{
|
||||
@@ -153,6 +171,12 @@ INSERT INTO api_interface (
|
||||
"value_field": "account_id"
|
||||
}
|
||||
}'::jsonb,
|
||||
'{
|
||||
"success_field": "code",
|
||||
"success_value": 0,
|
||||
"message_field": "message",
|
||||
"list_path": "data.list"
|
||||
}'::jsonb,
|
||||
'{
|
||||
"table_name": "tencent_video",
|
||||
"columns": [
|
||||
@@ -182,7 +206,7 @@ INSERT INTO api_interface (
|
||||
{"name": "quality_status", "type": "VARCHAR(50)", "comment": "质量状态"},
|
||||
{"name": "aigc_flag", "type": "VARCHAR(50)", "comment": "AIGC标志"},
|
||||
{"name": "muse_aigc_version", "type": "INT", "comment": "Muse AIGC版本"},
|
||||
{"name": "verify_status", "type": "VARCHAR(50) DEFAULT 'PENDING'", "comment": "校验状态"},
|
||||
{"name": "verify_status", "type": "VARCHAR(50)", "comment": "校验状态"},
|
||||
{"name": "verified_at", "type": "TIMESTAMP WITH TIME ZONE", "comment": "校验时间"},
|
||||
{"name": "verified_by", "type": "VARCHAR(64)", "comment": "校验人"}
|
||||
],
|
||||
@@ -192,13 +216,15 @@ INSERT INTO api_interface (
|
||||
|
||||
-- 2.4 音频素材接口(POST + JSON Body,无需遍历账户)
|
||||
-- 注意:此接口不依赖 account_id,不依赖 prefetch,不支持增量
|
||||
-- 出参:{"code":0, "message":"ok", "data":{"list":[...], "page_info":{...}}}
|
||||
-- 列表路径:data.list,分页:data.page_info.total_page
|
||||
INSERT INTO api_interface (
|
||||
tenant_id, creator, created_at, updater, updated_at,
|
||||
platform_id, name, code, url, method, status, auth_type,
|
||||
request_config, table_definition
|
||||
request_config, response_config, table_definition
|
||||
) VALUES (
|
||||
1, 'admin', NOW(), 'admin', NOW(),
|
||||
1,
|
||||
(SELECT id FROM api_datasource_platform WHERE platform_code = 'tencent'),
|
||||
'音频素材', 'audio',
|
||||
'/muse_audios/get', 'POST', 'active', 'inherit',
|
||||
'{
|
||||
@@ -208,6 +234,12 @@ INSERT INTO api_interface (
|
||||
"page_size_param": "page_size",
|
||||
"fields": ["audio_id", "cover_image_url", "audio_name", "author", "duration", "expire_time", "feel_tags", "genre_tags"]
|
||||
}'::jsonb,
|
||||
'{
|
||||
"success_field": "code",
|
||||
"success_value": 0,
|
||||
"message_field": "message",
|
||||
"list_path": "data.list"
|
||||
}'::jsonb,
|
||||
'{
|
||||
"table_name": "tencent_audio",
|
||||
"columns": [
|
||||
@@ -219,7 +251,7 @@ INSERT INTO api_interface (
|
||||
{"name": "expire_time", "type": "BIGINT", "comment": "过期时间戳"},
|
||||
{"name": "feel_tags", "type": "JSONB", "comment": "情感标签"},
|
||||
{"name": "genre_tags", "type": "JSONB", "comment": "风格标签"},
|
||||
{"name": "verify_status", "type": "VARCHAR(50) DEFAULT 'PENDING'", "comment": "校验状态"},
|
||||
{"name": "verify_status", "type": "VARCHAR(50)", "comment": "校验状态"},
|
||||
{"name": "verified_at", "type": "TIMESTAMP WITH TIME ZONE", "comment": "校验时间"},
|
||||
{"name": "verified_by", "type": "VARCHAR(64)", "comment": "校验人"}
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user