2017 © Pedro Peláez
 

library gci-php-sdk

Google Code-in Task API SDK

image

dragooon/gci-php-sdk

Google Code-in Task API SDK

  • Tuesday, March 29, 2016
  • by Dragooon
  • Repository
  • 1 Watchers
  • 0 Stars
  • 0 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Google Code-in API SDK for PHP

This API can be used to access Google Code-in's Task API to request, update and modify task definition, (*1)

Installation

Library can be installed from composer using composer require dragooon/gci-php-sdk or adding dragooon/gci-php-sdk to your composer dependencies, (*2)

Example

This is a simplified example of handling tasks via the API, (*3)

$client = new Dragooon\GCI\Client('<api key>');
$taskList = $client->getTasks(2); // Get tasks from second page
foreach ($taskList as $task) {
    echo $task->getId() . ' ' . $task->getName(); // See src/TaskInterface.php for full function list
}
$nextPage = $taskList->getNextPage();

// Get the details of a single task
$id = 123; // Task ID
$task = $client->getTask($id);
echo $task->getDescription();

// Create a new task
$task = new Task([
    'name' => 'Test task',
    'description' => 'Testing a new task',
    'status' => Dragooon\GCI\TaskInterface::STATUS_DRAFTED,
]);
$client->createTask($task);

License

The MIT License (See LICENSE), (*4)

The Versions

29/03 2016

dev-master

9999999-dev

Google Code-in Task API SDK

  Sources   Download

MIT

The Requires

 

api google sdk code-in