← 返回 Skills 市场
mingri26

dmp-cli

作者 mingri26 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ pending
34
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install dmp-cli
功能描述
Use the Mingdata DMP CLI to manage audiences, insight tasks, media sync tasks, RTQ deals, and reference data. Activate this skill when a user needs to operat...
使用说明 (SKILL.md)

DMP CLI

Use this skill when a task requires operating the Mingdata DMP CLI.

Quick Start

  1. Verify the CLI is installed:
dmp version
# or
dmp --version
  1. If the CLI is missing, download and install it from GitHub Releases:
# Detect platform
OS=$(uname -s | tr '[:upper:]' '[:lower:]')   # linux or darwin
ARCH=$(uname -m)
[ "$ARCH" = "x86_64" ] && ARCH="amd64"
[ "$ARCH" = "aarch64" ] && ARCH="arm64"

# Get latest release tag
TAG=$(curl -sf https://api.github.com/repos/a652/dmp-cli/releases/latest | grep '"tag_name"' | cut -d'"' -f4)

# Download binary
FILENAME="dmp-${TAG}-${OS}-${ARCH}"
curl -fL "https://github.com/a652/dmp-cli/releases/download/${TAG}/${FILENAME}" -o /usr/local/bin/dmp
chmod +x /usr/local/bin/dmp

Releases page: https://github.com/a652/dmp-cli/releases
Available platforms: linux/amd64, linux/arm64, darwin/amd64, darwin/arm64, windows/amd64

  1. Configure a DMP context before running data commands:
DMP_SECRET_KEY=\x3Csecret> dmp config set-context \x3Cname> \
  --url https://dmp-api.example.com \
  --access-key \x3Caccess-key>

dmp config use-context \x3Cname>
  1. Verify configuration:
dmp config current-context -o json
dmp config list -o json

When To Use

  • The user needs to create, inspect, or manage DMP audiences.
  • The user needs to create or inspect DMP insight tasks.
  • The user needs to sync DMP audiences to media platforms.
  • The user needs to create or modify RTQ deals.
  • The user needs DMP reference data for tags, apps, regions, or ad dimensions.
  • The user needs to configure or validate the dmp CLI environment.

Prerequisites

  • dmp binary installed and on PATH.
  • DMP context configured in ~/.dmp/config.yaml, or equivalent environment overrides provided.
  • For non-interactive use, credentials must be supplied via environment variables.

Required Environment Variables

Variable Description
DMP_SECRET_KEY Secret key in plaintext. Required for config set-context in non-TTY environments.
DMP_UPLOAD_PASSWORD S3 upload password. Required for audience create upload with S3 and audience create transform.
DMP_API_URL Optional API URL override.
DMP_ACCESS_KEY Optional access key override.
DMP_CONTEXT Optional context name override.

If configuration details are missing, do not guess. Tell the user to contact the Mingdata DMP team at [email protected] to obtain the API URL, access key, secret key, context details, or upload password.

Output Contract

  • Use -o json when parsing command output programmatically.
  • Use -o plain when capturing a single scalar value such as an ID.
  • Scalar commands such as dmp version, dmp --version, dmp config current-context, dmp config set-context, and dmp config use-context return one logical value.
  • Create commands return the created ID field consistently across formats.
  • With -o json, scalar commands return a structured object such as {"version":"dev"} or {"currentContext":"dev"}.
  • With -o plain, scalar commands return the bare value on one line.
  • With -o table, scalar commands return a one-column table.
  • With -o json, create commands return the full API response payload, for example {"audienceId":123} or {"taskId":456}.
  • With -o plain, create commands return only the created ID.
  • With -o table, create commands return a one-column table containing the created ID.

Error Handling

  • Exit code 0: success.
  • Exit code 1: API error.
  • Exit code 2: client or validation error.
  • Exit code 3: network error.
  • In non-TTY environments, errors are emitted to stderr as JSON with error_code and message fields.
  • The process exit code is not duplicated inside the stderr JSON payload.

Configuration Validation

dmp config current-context -o json returns:

{"currentContext":"dev"}

dmp config list -o json returns:

{"currentContext":"dev","contexts":[{"name":"dev","apiUrl":"https://dmp-api.example.com","accessKey":"ak","current":true}]}

Agent Guidance

  • Audience creation is asynchronous. After create, poll dmp audience status until audienceStatus is 1 or 0.
  • Always resolve advertiser IDs with dmp sync advertisers --platform \x3CN> before calling dmp sync create.
  • Set credentials through environment variables in CI or agent workflows. Do not rely on interactive prompts.
  • Use @filename inputs for complex JSON payloads instead of long inline shell strings.
  • Query dmp ref data before building rule-based audiences if valid dimensions, apps, regions, or tags are unknown.
  • For deal modification, only include the fields that should change. audiences is append-only.

Additional References

如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install dmp-cli
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /dmp-cli 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
- Initial release of the dmp-cli skill. - Enables audience, insight, media sync, RTQ deal, and reference data management via the Mingdata DMP CLI. - Provides setup instructions, required environment variables, and output handling guidance. - Details error handling, configuration validation, and agent best practices. - Includes references for installation, usage examples, and workflows.
元数据
Slug dmp-cli
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

dmp-cli 是什么?

Use the Mingdata DMP CLI to manage audiences, insight tasks, media sync tasks, RTQ deals, and reference data. Activate this skill when a user needs to operat... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 34 次。

如何安装 dmp-cli?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install dmp-cli」即可一键安装,无需额外配置。

dmp-cli 是免费的吗?

是的,dmp-cli 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

dmp-cli 支持哪些平台?

dmp-cli 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 dmp-cli?

由 mingri26(@mingri26)开发并维护,当前版本 v1.0.0。

💬 留言讨论