Using the Redmine REST API with PHP
The REST API is widely used by third-party applications. This recipe teaches you how to use a basic PHP application that connects to Redmine. For this example, we are going to create a sample app that submits issue to a project. Such applications can be used, for example, on website contact forms, and initiate a support or CRM request.
Getting ready
Before you begin, research ready-made examples and libraries that you can use in your project.
This recipe assumes that you know either PHP, HTML or C# (Windows forms).
How to do it…
One of Redmine's PHP libraries that updates often is kbsali's library, which can be forked or downloaded from https://github.com/kbsali/php-redmine-api.
To create your first Redmine app, perform the following steps:
In your
www-root
, create a folder calledphprmtest
(short for PHP Redmine test).Download and extract
php-redmine-api
library tophprmtest
.Create a file called
test.php
.Paste the following contents, replacing the values in...