ZenHub API で Estimate を更新する方法

ZenHub API で Estimate を更新する方法をご紹介します。

ZenHub

背景 ZenHub API で Estimate を一括更新したい

GitHub issue を一括作成した後に ZenHub API で Estimate を一括設定したくなり、実践してみたのが本記事です。

ZenHub API で Estimate を更新する

PUT /p1/repositories/:repo_id/issues/:issue_number/estimate という ZenHub API を利用して Estimate を設定します。

ZENHUB_API_TOKEN_HEADER='X-Authentication-Token: xxxxxx'

curl -X PUT \
-H ${ZENHUB_API_TOKEN_HEADER} \
-H 'Content-Type: application/json' \
https://api.zenhub.com/p1/repositories/:repo_id/issues/:repo_id/estimate \
-d '{ "estimate": 8 }'

以上、ZenHub API で Estimate を更新した、現場からお送りしました。