2017 © Pedro Peláez
 

library worksnaps-bundle

Bundle provide ability work with Worksnaps API.

image

makarenko/worksnaps-bundle

Bundle provide ability work with Worksnaps API.

  • Sunday, September 4, 2016
  • by ynmakarenko
  • Repository
  • 1 Watchers
  • 1 Stars
  • 14 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Worksnaps API client - Symfony Bundle

SensioLabsInsight, (*1)

Install the Bundle

composer require makarenko/worksnaps-bundle, (*2)

Enable the Bundle

// app/AppKernel.php

// ...
class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = array(
            // ...

            new Umbrella\WorksnapsBundle\WorksnapsBundle(),
        );

        // ...
    }

    // ...
}

Configure the Bundle

# app/config/config.yml
worksnaps:
    api_key: "YOUR API KEY HERE"

Working in code

Project API

Get all projects

$allProjects = $this->get('umbrella.worksnaps')->getProjects();, (*3)

Get project by ID

$project = $this->get('umbrella.worksnaps')->getProject( $projectId );, (*4)

======, (*5)

Task API

Get tasks in project

$tasks = $this->get('umbrella.worksnaps')->getTasks( $projectId );, (*6)

Get task

$task = $this->get('umbrella.worksnaps')->getTask( $projectId, $taskId );, (*7)

======, (*8)

User Assignment API

Get users from project

$users = $this->get('umbrella.worksnaps')->getUsersFromProject( $projectId );, (*9)

Get user from project

$user = $this->get('umbrella.worksnaps')->getUserFromProject( $projectId, $userId );, (*10)

======, (*11)

User Account API

Get my user

$myUser = $this->get('umbrella.worksnaps')->getMyUser();, (*12)

Get users

$users = $this->get('umbrella.worksnaps')->getUsers();, (*13)

get user

$user = $this->get('umbrella.worksnaps')->getUser( $userId );, (*14)

======, (*15)

Task Assignment API

Get tasks assignments in a project

$tasksInProject = $this->get('umbrella.worksnaps')->getTasksFromProject( $projectId );, (*16)

Get task assignment in a project

$taskInProject = $this->get('umbrella.worksnaps')->getTaskFromProject( $projectId, $taskId );, (*17)

======, (*18)

Time Entry API

Get time entries in the specified project

$timeEntries = $this->get('umbrella.worksnaps')->getTimeEntries( $projectId, array( $userId ), $fromTimestamp, $toTimestamp );, (*19)

Get time entries of the specified user in the specified project

$timeEntriesForUser = $this->get('umbrella.worksnaps')->getTimeEntriesForUser( $projectId, $userId, $fromTimestamp, $toTimestamp );, (*20)

Get the URL of full resolution screenshot of a time entry

$fullUrl = $this->get('umbrella.worksnaps')->getScreenshot( $projectId, $timeEntryId );, (*21)

Get time entry

$timeEntry = $this->get('umbrella.worksnaps')->getTimeEntry( $projectId, $timeEntryId );, (*22)

======, (*23)

Report API

$report = $this->get('umbrella.worksnaps')->getReport( $projectId, $fromTimestamp, $toTimestamp, [ $userId ] );, (*24)

The Versions

04/09 2016

dev-master

9999999-dev

Bundle provide ability work with Worksnaps API.

  Sources   Download

MIT

by Yuri Makarenko

04/09 2016

dev-update-readme

dev-update-readme

Bundle provide ability work with Worksnaps API.

  Sources   Download

MIT

by Yuri Makarenko