PHP code example of manavo / donedone-api-php

1. Go to this page and download the library: Download manavo/donedone-api-php library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

manavo / donedone-api-php example snippets


$client = new Manavo\DoneDone\Client('team_name', 'username', 'password/api_token');
$projects = $client->projects();

$client = new Manavo\DoneDone\Client('team_name', 'username', 'password/api_token');
$priorityLevels = $client->priorityLevels();

$client = new Manavo\DoneDone\Client('team_name', 'username', 'password/api_token');
$people = $client->project(1234)->people();

$client = new Manavo\DoneDone\Client('team_name', 'username', 'password/api_token');
$issues = $client->project(1234)->issues();
$activeIssues = $client->project(1234)->activeIssues();
$closedAndFixedIssues = $client->project(1234)->closedAndFixedIssues();

$client = new Manavo\DoneDone\Client('team_name', 'username', 'password/api_token');

$project = $client->project(1111);

$issue = new \Manavo\DoneDone\Issue();
$issue->setTitle('Brand new issue!');
$issue->setPriorityLevel(1);
$issue->setFixer(4321);
$issue->setTester(1234);
$issue->addAttachment('/path/to/some/file.md'); // Optional

$addedIssue = $project->addIssue($issue);

$client = new Manavo\DoneDone\Client('team_name', 'username', 'password/api_token');
$issue = $client->project(29881)->issue(16);

$comment = new \Manavo\DoneDone\Comment();
$comment->setMessage('I am commenting!!!');
$comment->addAttachment('/path/to/some/file.md'); // Optional

$addedComment = $issue->addComment($comment);

composer