-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(qianchuan/material): 增加获取账户下素材列表
- Loading branch information
Showing
13 changed files
with
333 additions
and
153 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
13 changes: 13 additions & 0 deletions
13
marketing-api/api/qianchuan/material/ad_material_delete.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package material | ||
|
||
import ( | ||
"context" | ||
|
||
"github.com/bububa/oceanengine/marketing-api/core" | ||
"github.com/bububa/oceanengine/marketing-api/model/qianchuan/material" | ||
) | ||
|
||
// AdMaterialDelete 删除广告创意 | ||
func AdMaterialDelete(ctx context.Context, clt *core.SDKClient, accessToken string, req *material.AdMaterialDeleteRequest) error { | ||
return clt.Post(ctx, "v1.0/qianchuan/ad/material/delete/", req, nil, accessToken) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package material | ||
|
||
import ( | ||
"context" | ||
|
||
"github.com/bububa/oceanengine/marketing-api/core" | ||
"github.com/bububa/oceanengine/marketing-api/model/qianchuan/material" | ||
) | ||
|
||
// AdMaterialGet 获取计划下素材列表 | ||
// 获取计划下的素材信息,包括素材的元信息,审核状态,关联创意ID,派生信息,是否删除等。 | ||
func AdMaterialGet(ctx context.Context, clt *core.SDKClient, accessToken string, req *material.AdMaterialGetRequest) (*material.AdMaterialGetResult, error) { | ||
var resp material.AdMaterialGetResponse | ||
if err := clt.GetAPI(ctx, "v1.0/qianchuan/ad/material/get/", req, resp, accessToken); err != nil { | ||
return nil, err | ||
} | ||
return resp.Data, nil | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// Package material 广告素材管理 | ||
package material |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package material | ||
|
||
import ( | ||
"context" | ||
|
||
"github.com/bububa/oceanengine/marketing-api/core" | ||
"github.com/bububa/oceanengine/marketing-api/model/qianchuan/material" | ||
) | ||
|
||
// Get 获取账户下素材列表 | ||
func Get(ctx context.Context, clt *core.SDKClient, accessToken string, req *material.GetRequest) (*material.GetResult, error) { | ||
var resp material.GetResponse | ||
if err := clt.GetAPI(ctx, "v1.0/qianchuan/material/get/", req, resp, accessToken); err != nil { | ||
return nil, err | ||
} | ||
return resp.Data, nil | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// Package material 广告素材管理 | ||
package material |
Oops, something went wrong.