List
Description: Provides a paginated list of all projects that the user has access to.
Endpoint: <base_url>/projects.json
Request: GET
Formats supported: JSON
Params:
- page - {Integer} of the page (Default: 1)
Response
{
"pagination": { .... },
"projects": [
{ .... },
{ .... }
]
}
Example ruby request
HTTParty.get('https://api.testlodge.com/v1/account/1/projects.json')
Example Response
Response code: 200
{
"pagination": {
"total_entries":2,
"total_pages":1,
"current_page":1,
"next_page":null,
"previous_page":null,
"per_page":15
},
"projects":[{
"id":1,
"name":"TestLodge Test scripts",
"description":null,
"issue_tracker_credential_id":1,
"issue_tracker_project_id":"20",
"created_at":"2014-02-26T14:33:58Z",
"updated_at":"2014-02-26T14:33:58Z"
},
{ .... }]
}
Show
Description: Get the details for a single project.
Endpoint: <base_url>/projects/{id}.json
Request: GET
Formats supported: JSON
Params:
- id - {Integer} The project ID (Required)
Response
{ .... }
Example ruby request
HTTParty.get('https://api.testlodge.com/v1/account/1/projects/1.json')
Example Response
Response code: 200
{
"id":1,
"name":"TestLodge Test scripts",
"description":null,
"issue_tracker_credential_id":1,
"issue_tracker_project_id":"20",
"created_at":"2014-02-26T14:33:58Z",
"updated_at":"2014-02-26T14:33:58Z"
}
Create
Description: Create a new project.
Endpoint: <base_url>/projects.json
Request: POST
Formats supported: JSON
Params:
- project:
- name - {String} The project name (Required)
- description - {Text} The project description
- issue_tracker_credential_id - {Integer} The ID of one of your integrated issue trackers
- issue_tracker_project_id - {String} If you have provided an issue_tracker_credential_id, also the issue tracker project id/key to associate with the new TestLodge project
Response
{ .... }
Example ruby request
HTTParty.post('https://api.testlodge.com/v1/account/1/projects.json', body: {
project: {
name: 'Example',
description: 'A example project'
}
})
Example Response
Response code: 201
{
"id":1,
"name":"Example",
"description":"A example project",
"issue_tracker_credential_id":null,
"issue_tracker_project_id":null,
"created_at":"2014-02-26T14:33:58Z",
"updated_at":"2014-02-26T14:33:58Z"
}
Update
Description: Update a project.
Endpoint: <base_url>/projects/{id}.json
Request: PATCH
Formats supported: JSON
Params:
-
id - {Integer} The project ID (Required)
- project:
- name - {String} The project name
- description - {Text} The project description
- issue_tracker_credential_id - {Integer} The ID of one of your integrated issue trackers
- issue_tracker_project_id - {String} If you have provided an issue_tracker_credential_id, also the issue tracker project id/key to associate with the new TestLodge project
Response
{ .... }
Example ruby request
HTTParty.patch('https://api.testlodge.com/v1/account/1/projects/1.json', body: {
project: {
description: 'A new description'
}
})
Example Response
Response code: 200
{
"id":1,
"name":"Example",
"description":"A new description",
"issue_tracker_credential_id":null,
"issue_tracker_project_id":null,
"created_at":"2014-02-26T14:33:58Z",
"updated_at":"2014-02-26T14:33:58Z"
}
Delete
Description: Delete a project and all of its content.
Endpoint: <base_url>/projects/{id}.json
Request: DELETE
Formats supported: JSON
Params:
- id - {Integer} The project ID (Required)
Response
empty
Example ruby request
HTTParty.delete('https://api.testlodge.com/v1/account/1/projects/1.json')
Example Response
Response code: 204
empty
Comments
Article is closed for comments.