0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

BacklogAPIを用いたデータの取得メモ

Posted at

BacklogにはAPIが用意されているが、
https://developer.nulab.com/ja/docs/backlog/#backlog-api-%E3%81%A8%E3%81%AF

何でもできる、ってのはわかるのだが、ちょっとしたツールを暇だったので作ってみた。その際にDataFrameを用いたデータ取得を使ったのだが、あまりDataFrameに慣れていなかったので、若干試行錯誤した。

r = requests.get(url, params=params, proxies=proxy_dict)
if r.status_code == requests.codes.ok:
	data = r.json()

としたときに、どのようにデータを取るかについて、慣れれば簡単なのだが、私はPython初心者なのでメモ。

"projectId": 1, 

を取りたければ、data["projectId"]

"status": { 
    "id": 1,

を取りたいのであれば、data["status"]["id"]

stars配下の

"url": "https://xx.backlog.jp/view/BLG-1",

を取りたいのであれば、data["stars"][0]["url"]

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?