teratail header banner
teratail header banner
質問するログイン新規登録

回答編集履歴

3

回答追記

2019/01/28 17:09

投稿

退会済みユーザー
answer CHANGED
@@ -15,4 +15,23 @@
15
15
  ---
16
16
  **追記 1/14 11:10**
17
17
  このQUERY PARAMS使えばカード丸ごと(チェックリストも)コピーしてくれるかもしれません。。。(試してないから分かりません)
18
- **idCardSource**:The ID of a card to copy into the new card
18
+ **idCardSource**:The ID of a card to copy into the new card
19
+
20
+ ---
21
+ **追記 1/29 02:10**
22
+
23
+ ```GoogleAppScript
24
+ function copyCard(){
25
+ var trelloKey = "xxxxxxxxxxxxx";//key
26
+ var trelloToken = "xxxxxxxxxxxxx";//token
27
+ var idList = 'xxxxxxxxxxxxx'; //コピー先のリストのID
28
+ var idCardSource = 'xxxxxxxxxxxxx';//コピー元のカードのID
29
+
30
+
31
+ var url = 'https://api.trello.com/1/cards?idList=' + idList + '&idCardSource=' + idCardSource + '&key=' + trelloKey + '&token=' + trelloToken ;
32
+ var res = UrlFetchApp.fetch(url, {'method':'post'});
33
+
34
+ Logger.log(res);
35
+
36
+ }
37
+ ```

2

追記

2019/01/28 17:09

投稿

退会済みユーザー
answer CHANGED
@@ -10,4 +10,9 @@
10
10
  [POST https://api.trello.com/1/cards](https://developers.trello.com/reference/#cards-2)についてのQUERY PARAMSにidChecklistは載っていないですね。
11
11
  以下の二つのどちらかを使うしかなさそうです。
12
12
  [POST https://api.trello.com/1/cards/id/checklists](https://developers.trello.com/reference/#cardsidchecklists-1)
13
- [POST https://api.trello.com/1/checklists](https://developers.trello.com/reference/#checklists)
13
+ [POST https://api.trello.com/1/checklists](https://developers.trello.com/reference/#checklists)
14
+
15
+ ---
16
+ **追記 1/14 11:10**
17
+ このQUERY PARAMS使えばカード丸ごと(チェックリストも)コピーしてくれるかもしれません。。。(試してないから分かりません)
18
+ **idCardSource**:The ID of a card to copy into the new card

1

追記

2019/01/14 02:13

投稿

退会済みユーザー
answer CHANGED
@@ -3,4 +3,11 @@
3
3
  [/checklists](https://developers.trello.com/reference/#checklists)
4
4
 
5
5
  もしチェックリストのコピーが不要だとしてKodanosukeさんのコードが上手く動く場合
6
- 二つのカード間でチェックリストを共有することになってしまうのでそれだとタスク管理にならないのではないかと思いました。
6
+ 二つのカード間でチェックリストを共有することになってしまうのでそれだとタスク管理にならないのではないかと思いました。
7
+
8
+ ---
9
+ **追記 1/14 11:00**
10
+ [POST https://api.trello.com/1/cards](https://developers.trello.com/reference/#cards-2)についてのQUERY PARAMSにidChecklistは載っていないですね。
11
+ 以下の二つのどちらかを使うしかなさそうです。
12
+ [POST https://api.trello.com/1/cards/id/checklists](https://developers.trello.com/reference/#cardsidchecklists-1)
13
+ [POST https://api.trello.com/1/checklists](https://developers.trello.com/reference/#checklists)