Merge Requests Fields
To fetch metadata of Merge Request object send a GET request to:
https://api.assembla.com/v1/meta/merge_requests.(json|xml)
example. request json with curl utility:
curl -H "authorization: bearer _token" https://api.assembla.com/v1/meta/merge_requests.json
example. request xml with curl utility:
curl -H "authorization: bearer _token" https://api.assembla.com/v1/meta/merge_requests.xml
table below is the list of fields contained in the response, this list will be properly formatted to json or xml as requested.
Fields
| Param | Data type | Access | Description |
|---|---|---|---|
| commit | string | read | SHA1 id of merge request starting commit |
| created_at | datetime | read | Date of merge request creation |
| description | string | read/write | Merge request description |
| id | integer | read | Merge request identifier |
| processed_by_user_id | string | read | ID of the user that merged/ignored the merge request |
| source_cleanup | integer | read/write | Shows if source branch will be deleted after merge request is merged/ignored. The values in bold are possible:
|
| source_symbol | string | read/write | Source symbol (name of a branch, a tag or SHA1 of a revision) |
| source_symbol_type | string | read | Source symbol type. The values in bold are possible:
|
| space_tool_id | string | read | ID of the space tool merge request belongs to |
| status | integer | read | Status of the merge request. The values in bold are possible:
|
| target_space_tool_id | string | read/write | ID of space tool merge request will be merged into |
| target_space_id | string | read | ID of space merge request will be merged into |
| target_symbol | string | read/write | Name of branch in target space tool |
| title | string | read/write | Title of the merge request |
| updated_at | datetime | read | Date of merge request last update |
| url | string | read | URL where the merge request may be found at. Has the following form: https://www.assembla.com/spaces/_space_id/space_tools/_space_tool_id/merge_requests/_id.
Note: you have to either append a format (like json or xml) to the URL or send a HTTP_ACCEPT header, which will denote the needed format. |
| user_id | string | read | ID of the user that created the merge request |
Validations
| Field | Validator | Description |
|---|---|---|
| title | presence validator | Title should be present. |
| source_symbol | presence validator | Source symbol should be present. |
| target_symbol | presence validator | Target symbol should be present. |