Not archived Trello list in php

Hi I’m doing a Trello power up but I have a problem I’m trying to archive the lists on a board but I can’t and I get this error :
public 'code' => int 400 public 'raw_body' => string 'invalid value for value' (length=23) public 'body' => string 'invalid value for value'

php example code:

$response = Unirest\Request::put("https://api.trello.com/1/lists/".$id."/closed?key=***&token=***" );

Trello Documents
https://developer.atlassian.com/cloud/trello/rest/api-group-lists/#api-lists-id-closed-put

Can you help solve this problem?

Hi,

There’s a ‘value’ query param that has to be set to true in order to close (archive) the list.

Change your request to "https://api.trello.com/1/lists/".$id."/closed?key=***&token=***&value=true"

It should work :slight_smile:

1 Like

Thanks It’s so helped :grinning: