REST project servers
Project servers define the integration parameters (URL, user name, and password) for external ticketing or automation resources.
GET /v1/project_servers
Returns all project servers
Filters
- name — String for project_servers name
- active — Boolean value to show active project_servers (default is to show only active project_servers)
- inactive — Boolean value to show inactive project_servers
Common attributes
- format — Ensure to include an accept header or add .xml or .json to the last path element
- token — Your API Token for authentication
Errors caused
- ERROR 403 Forbidden — Occurs when the token is invalid
- ERROR 404 Not Found — Occurs when no records are found
Examples
To test this method, insert this URL or your valid API key and application host into a browser or HTTP client like wget or curl. For example:
An example of filters:
GET /v1/project_servers/[id]
Returns a project_server by ID
Common attributes
- id — Numerical unique ID for record
- format — Ensure to include an accept header or add .xml or .json to the last path element
- token — Your API Token for authentication
Errors caused
- ERROR 403 Forbidden — Occurs when the token is invalid
- ERROR 404 Not found — Occurs when record to show is not found
Examples
To test this method, insert this URL or your valid API key and application host into a browser or HTTP client like wget or curl. For example:
POST /v1/project_servers
Creates a new project server.
Required attributes
- name — String name of the project server
- server_name_id — Unique integer ID for identifying the project server type:
- 1 = Rally
- 2 = Jira
- 3 = Mantis
- 4 = ServiceNow
- 5 = Hudson
- 6 = SSH
- 7 = Streamstep
- server_url — String URL of the server
- username — String user name for the project server
Optional attributes
- details — String description of the project server
- ip — String IP address for the project server
- password — String password for the project server
- port — Integer port number for the project server (optional except for Jira server name ID 2)
- project_ids — Array of integer IDs for related projects
- query_ids — Array of integer IDs for related queries
- release_ids — Array of integer IDs for releases
- ticket_ids — Array of integer IDs for tickets
Common attributes
- format — Ensure to include an accept header or add .xml or .json to the last path element
- token — Your API Token for authentication
Errors caused
- ERROR 403 Forbidden — Occurs when the token is invalid
- ERROR 422 Unprocessable entity — Occurs when validation fails and objects and errors are returned
Examples
To test this method, insert this URL or your valid API key and application host into a browser or HTTP client like wget or curl. For example:
PUT /v1/project_servers/[id]
Updates an existing project_server with values from a posted document.
Editable attributes
- details — String description of the project server
- ip — String IP address for the project server
- name — String name of the project server
- password — String password for the project server
- port — Integer port number for the project server (optional except for Jira server name ID 2)
- project_ids — Array of integer IDs for related projects
- query_ids — Array of integer IDs for related queries
- release_ids — Array of integer IDs for releases
- server_name_id— Integer identifying the project server type:
- 1 = Rally
- 2 = Jira
- 3 = Mantis
- 4 = ServiceNow
- 5 = Hudson
- 6 = SSH
- 7 = Streamstep
- server_url — String URL of the server (required)
- ticket_ids — Array of integer IDs for tickets
- username — String username for the project server
Toggle archival status
- toggle_archive — Boolean value that will toggle the archive status of an object
Common attributes
- format — Ensure to include an accept header or add .xml or .json to the last path element
- token — Your API Token for authentication
Errors caused
- ERROR 403 Forbidden — Occurs when the token is invalid
- ERROR 404 Not found — Occurs when record to update is not found
- ERROR 422 Unprocessable entity — Occurs when validation fails and objects and errors are returned
Examples
To test this method, insert this URL or your valid API key and application host into a browser or HTTP client like wget or curl. For example:
DELETE /v1/project_servers/[id]
Makes a project server inactive. Sets the active parameter for the project server to false.
Common attributes
- id — Unique numerical ID for the project server record
- format — Ensure to include an accept header or add .xml or .json to the last path element
- token — Your API Token for authentication
Errors caused
- ERROR 403 Forbidden — Occurs when the token is invalid
- ERROR 404 Not found — Occurs when no records are found
Examples
To test this method, insert this URL or your valid API key and application host into a browser or HTTP client like wget or curl. For example:
Sample output
The following JSON is a sample output from GET /v1/project_servers:
Server: Apache-Coyote/1.1
X-UA-Compatible: IE=Edge
ETag: "105cafdd20b6862b8044237792553958"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: 7fe2e0e5d262ad9a524b08fdce339226
X-Runtime: 0.112000
Content-Type: application/json;charset=utf-8
Content-Length: 431
Date: Wed, 24 Oct 2012 13:30:04 GMT
[{
"details": null,
"id": 1,
"ip": null,
"name": "Sample Project Server",
"port": null,
"server_name_id": 1,
"server_url": "http://www.example.com",
"username": "admin",
"projects": [],
"parent_projects": [],
"releases": [],
"tickets": []
}]
The following XML is a sample output from GET /v1/project_servers/1:
Server: Apache-Coyote/1.1
X-UA-Compatible: IE=Edge
ETag: "2f85278391473b3be5d112e2b0df8a84"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: 8777b7675ad6aa1c460bbcf0aa9aa62c
X-Runtime: 0.165000
Content-Type: application/xml;charset=utf-8
Content-Length: 1031
Date: Wed, 24 Oct 2012 13:28:57 GMT
<?xml version="1.0" encoding="UTF-8"?>
<project-servers type="array">
<project-server>
<details nil="true"></details>
<id type="integer">2</id>
<ip nil="true"></ip>
<name>Sample Project Server</name>
<port type="integer" nil="true"></port>
<server-name-id type="integer">1</server-name-id>
<server-url>http://www.example.com</server-url>
<username>admin</username>
<projects type="array"/>
<parent-projects type="array"/>
<releases type="array"/>
<tickets type="array"/>
</project-server>
</project-servers>
Related topic