openproject-ticket-system
openproject-ticket-system copied to clipboard
A small PHP-Script for turning OpenProject in a E-Mail based ticket system
A PHP-Script that turns OpenProject into a ticket system.
This small PHP script works as follows:
- Called periodically via cronjob
- If new mails are in the Inbox (e.g. [email protected])
- The script automatically creats a ticket
- If the user has no account a account is created and invitation mail is sent to user
- If the user has no support-project assigned (identifier contains "support") a new project is created. This is needed because otherwise the user would see the support tickets of other projects/user
- If the user has an account and a support-project, the ticket is created in this support-project
- A mail to the user is sent with information about the ticket (number, link)
- Slack integration: After ticket creation a message is sent to slack channel
- Rocket.Chat integration: After ticket creation a message is sent to rocket chat channel
- Job integration: For every incoming mail to a job adress an automatic ticket is created in the ticket project inside OpenProject and assigned to the human ressource person
- Reply to ticket (with ticket id in subject): A comment on the ticket is created
Infos
- Find more infos in this blog post about "Ticketing-System mit OpenProject" - German only.
- Blog post update here
Updates
- composer support
- slack integration
- Rocket.Chat integration
- installation instruction
- creation of tickets from job mailbox
- reply to ticket (with ticket id in subject): A comment on the ticket is created
Features
- Turn OpenProject in a ticket system
- Slack Integration
- Rocket.Chat Integration
- Support for job applications
Requirements
- Web server with php 7+
- OpenProject server with version 8.0.0+
- Mail server (mail box as imap available)
Installation
- Configure OpenProject
- Configure user creation (users will get mail for activation)
- Get api key
- Create user role for new users
- Copy script on server
- Execute composer install
- Create directory "attachments" in root directory
- Check config values in file index.php (const variables)
- Check config values in code.php (const variables)
- Create Cronjob to run the script periodically
- Change default messages for mail reply's
- Remove some varioous specific checks (e.q. we always check for {Spam?} in mail subject, because our mail scanner always add's this to subject if mail is possible spam.
Compatibility
- OpenProject 8.0.0-10.5.1 (tested)
Useful informations
- The script marks mails as flagged if the already processed by the script
- OpenProject API v3 is used (newest API version)
Possible future improvments:
- Bot / spam check
- Make it available as OpenProject Plugin
Sponsorship
Development time and resources for this tool are provided by varioous, a digital agency based in upper austria.