2017 © Pedro Peláez
 

library todoist

Todoist Notifications driver

image

laravel-notification-channels/todoist

Todoist Notifications driver

  • Tuesday, August 23, 2016
  • by laravel-notification-channels
  • Repository
  • 1 Watchers
  • 2 Stars
  • 34 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 3 Versions
  • 13 % Grown

The README.md

Todoist notifications channel for Laravel 5.3

Latest Version on Packagist Software License Build Status StyleCI SensioLabsInsight Quality Score Code Coverage Total Downloads, (*1)

~This package makes it easy to create Todoist tasks with Laravel 5.3.~, (*2)

Channel Deprecated

Please see this issue for more infomation.
This channel was deprecated in Oct 2019 due to lack of a maintainer., (*3)

Contents

Installation

You can install the package via composer:, (*4)

``` bash composer require laravel-notification-channels/todoist, (*5)


### Setting up the Todoist service In order to add tickets to Todoist users, you need to obtain their access token. Create a [new Todoist App](https://developer.todoist.com/appconsole.html) to get started. ## Usage Now you can use the channel in your `via()` method inside the notification: ``` php use NotificationChannels\Todoist\TodoistChannel; use NotificationChannels\Todoist\TodoistMessage; use Illuminate\Notifications\Notification; class ProjectCreated extends Notification { public function via($notifiable) { return [TodoistChannel::class]; } public function toTodoist($notifiable) { return TodoistMessage::create('This is the ticket name.') ->priority(4) ->due('tomorrow'); } }

In order to let your Notification know which Todoist user and Todoist list you are targeting, add the routeNotificationForTodoist method to your Notifiable model., (*6)

This method needs to return the access token of the authorized Todoist user., (*7)

public function routeNotificationForTodoist()
{
    return 'NotifiableAccessToken';
}

Available methods

  • content(''): Accepts a string value for the Todoist ticket content.
  • projectId(''): Accepts an integer value for the Todoist project id, default is the "Inbox" project.
  • priority(''): Accepts an integer value for the ticket priority. It should be a number between 1 and 4, 4 for very urgent and 1 for natural.
  • indent(''): Accepts an integer value for the ticket indent level. It should be a a number between 1 and 4, where 1 is top-level.
  • itemOrder(''): Accepts an integer value for the ticket item order.
  • collapsed(): Marks the Todoist ticket as collapsed.
  • due(''): Accepts a string or DateTime object for the Todoist ticket due date.

Changelog

Please see CHANGELOG for more information what has changed recently., (*8)

Testing

bash $ composer test, (*9)

Security

If you discover any security related issues, please email m.pociot@gmail.com instead of using the issue tracker., (*10)

Contributing

Please see CONTRIBUTING for details., (*11)

Credits

License

The MIT License (MIT). Please see License File for more information., (*12)

The Versions