Table of Contents

Search

  1. Preface
  2. RulePoint Interfaces
  3. RulePoint Services
  4. Custom Service API
  5. Java Adapter for REST API
  6. RulePoint REST API
  7. Sample XML and JSON Requests and Responses
  8. RulePoint Pluggable Authentication Module
  9. HTTP Request and Response Attributes

Developer Guide

Developer Guide

Update Projects

Update Projects

Use the PUT method to update a project in RulePoint.

PUT Request in JSON Format

Generate a PUT request. For example, the following PUT request updates a project in a RulePoint application:
PUThttp: //localhost: 8080/rulepoint/api/projects/2 Accept: application/json Content-Type: application/json Cookie: JSESSIONID=<VALIDSESSIONID>

PUT Body in JSON Format

{ "name": "TestProject", "description": "Test Project" }

PUT Response in JSON Format

Returns the project object and response code 200 OK. Returns the error object if an error occurs.
{ "id": "2", "name": "TestProject", "valid": false, "self": { "rel": "self", "href": "api/projects/2" }, "actions": [ { "rel": "update", "href": "/api/projects/2", "type": "PUT" }, { "rel": "delete", "href": "/api/projects/2", "type": "DELETE" }, { "rel": "deploy", "href": "/api/projects/2/deploy", "type": "POST" }, { "rel": "undeploy", "href": "/api/projects/2/undeploy", "type": "POST" } ], "acl": { "rel": "acl", "href": "api/projects/2/acl", "title": "acl" }, "description": "Test Project" }
Response Code : 200 OK

PUT Request in XML Format

Generate a PUT request. For example, the following PUT request updates a project in a RulePoint application:
PUT http://localhost:8080/rulepoint/api/projects/98315 Accept: application/xml Content-Type: application/xml Cookie: JSESSIONID=<VALID SESSION ID>

PUT Body in XML Format

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <project> <name>TestProject</name> <description>Test Project</description> </project>

PUT Response in XML Format

Returns the project object and response code. Returns the error object if an error occurs.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <project> <acl> <href>api/projects/98315/acl</href> <rel>acl</rel> <title>acl</title> </acl> <actions> <action> <href>/api/projects/98315</href> <rel>update</rel> <type>PUT</type> </action> <action> <href>/api/projects/98315</href> <rel>delete</rel> <type>DELETE</type> </action> <action> <href>/api/projects/98315/deploy</href> <rel>deploy</rel> <type>POST</type> </action> <action> <href>/api/projects/98315/undeploy</href> <rel>undeploy</rel> <type>POST</type> </action> </actions> <id>98315</id> <links/> <name>TestProject</name> <self> <href>api/projects/98315</href> <rel>self</rel> </self> <valid>false</valid> <description>Test Project</description> </project>
Response Code : 200 OK

0 COMMENTS

We’d like to hear from you!