-
Notifications
You must be signed in to change notification settings - Fork 12
Methods: Projects
Fabian Beiner edited this page Nov 12, 2017
·
5 revisions
$allProjects = $Todoist->getAllProjects();
Example result:
print_r($allProjects);
(
[0] => stdClass Object
(
[id] => 123456789
[name] => Inbox
[order] => 0
[indent] => 1
[comment_count] => 0
)
[1] => stdClass Object
(
[id] => 987654321
[name] => Project
[order] => 1
[indent] => 1
[comment_count] => 0
)
…
)
$createProject = $Todoist->createProject('Example Project');
Example result:
print_r($createProject);
stdClass Object
(
[id] => 123454321
[name] => Example Project
[order] => 2
[indent] => 1
[comment_count] => 0
)
$project = $Todoist->getProject('123454321');
Example result:
print_r($project);
stdClass Object
(
[id] => 123454321
[name] => Example Project
[order] => 2
[indent] => 1
[comment_count] => 0
)
$Todoist->updateProject('123454321', 'New Project Name');
Example result:
print_r($Todoist->updateProject('123454321', 'New Project Name'));
1
$Todoist->deleteProject('123454321');
Example result:
print_r($Todoist->deleteProject('123454321'));
1
👋