QMetry: Fetch Defects or Issues
qmetry_fetch_defects_or_issuesFetch defects or issues from QMetry projects with automatic viewId resolution. Filter by release, cycle, or entity key, and paginate results.
Instructions
Fetch QMetry defects or issues - automatically handles viewId resolution based on project
Toolset: Issues
Parameters:
projectKey (string): Project key - unique identifier for the project (default: "default")
baseUrl (string): The base URL for the QMetry instance (must be a valid URL)
viewId (number): ViewId for issues - SYSTEM AUTOMATICALLY RESOLVES THIS. Leave empty unless you have a specific viewId. System will fetch project info using the projectKey and extract latestViews.IS.viewId automatically. Manual viewId only needed if you want to override the automatic resolution.
start (number): Start index for pagination - defaults to 0 (default: 0)
page (number): Page number to return (starts from 1) (default: 1)
limit (number): Number of records (default 10). (default: 10)
filter (string): Filter criteria as JSON string (default '[]') (default: "[]")
isJiraIntegrated (boolean): Send true if current project is Integrated with Jira (default: false)
sort (string): Sort Records - refer json schema, Possible property - entityKey, name, typeAlias, stateAlias, createdDate, createdByAlias, updatedDate, updatedByAlias, priorityAlias, createdSystem, linkedTcrCount, linkedRqCount, dfOwner, attachmentCount, environmentText (default: "[{"property":"name","direction":"ASC"}]")
Output Description: JSON object with 'data' array containing issues and pagination info
Use Cases: 1. List all issues in a project 2. Search for specific issues using filters 3. Get paginated issue results
Examples:
Get all issues from default project - system will auto-fetch viewId
{}Expected Output: List of issues from default project with auto-resolved viewId
Get all issues from UT project - system will auto-fetch UT project's viewId
{
"projectKey": "UT"
}Expected Output: List of issues from UT project using UT's specific IS viewId
Get issues with manual viewId (skip auto-resolution)
{
"projectKey": "MAC",
"viewId": 166065
}Expected Output: Issues using manually specified viewId 166065
List issues from specific project (ex: project key can be anything (VT, UT, PROJ1, TEST9)
{
"projectKey": "use specific given project key",
"viewId": "fetch specific project given projectKey defects or issues ViewId"
}Expected Output: Issues using manually specified viewId 103097 or projectKey
Get issues by release/cycle filter
{
"projectKey": "MAC",
"filter": "[{\"value\":[55178],\"type\":\"list\",\"field\":\"release\"},{\"value\":[111577],\"type\":\"list\",\"field\":\"cycle\"}]"
}Expected Output: Issues associated with Release 8.12 (ID: 55178) and Cycle 8.12.1 (ID: 111577)
Get issues by release only
{
"projectKey": "MAC",
"filter": "[{\"value\":[55178],\"type\":\"list\",\"field\":\"release\"}]"
}Expected Output: All defects or issues associated with Release 8.12 (ID: 55178)
Get issues by cycle only
{
"projectKey": "MAC",
"filter": "[{\"value\":[111577],\"type\":\"list\",\"field\":\"cycle\"}]"
}Expected Output: All defects or issues associated with Cycle 8.12.1 (ID: 111577)
Search for specific issue by entity key
{
"projectKey": "MAC",
"filter": "[{\"type\":\"string\",\"value\":\"MAC-IS-636\",\"field\":\"entityKeyId\"}]"
}Expected Output: Issues matching the entity key criteria
Search for multiple defects or issues by comma-separated entity keys
{
"projectKey": "MAC",
"filter": "[{\"type\":\"string\",\"value\":\"MAC-IS-636,MAC-IS-637,MAC-IS-638\",\"field\":\"entityKeyId\"}]"
}Expected Output: Issues matching any of the specified entity keys
Hints: 1. CRITICAL WORKFLOW: Always use the SAME projectKey for both project info and issues fetching 2. Step 1: If user specifies projectKey (like 'UT', 'MAC'), use that EXACT projectKey for project info 3. Step 2: Get project info using that projectKey, extract latestViews.IS.viewId 4. Step 3: Use the SAME projectKey and the extracted IS viewId for fetching issues 5. Step 4: If user doesn't specify projectKey, use 'default' for both project info and issues fetching 6. NEVER mix project keys - if user says 'MAC project', use projectKey='MAC' for everything 7. For search by issues key (like MAC-IS-1684), use filter: '[{"type":"string","value":"MAC-IS-1684","field":"entityKeyId"}]' 8. RELEASE/CYCLE FILTERING: Use release and cycle IDs, not names, for filtering 9. For release filter: '[{"value":[releaseId],"type":"list","field":"release"}]' 10. For cycle filter: '[{"value":[cycleId],"type":"list","field":"cycle"}]' 11. For combined release+cycle: '[{"value":[releaseId],"type":"list","field":"release"},{"value":[cycleId],"type":"list","field":"cycle"}]' 12. Get release/cycle IDs from FETCH_RELEASES_AND_CYCLES tool before filtering 13. FILTER FIELDS: name, stateAlias, typeAlias, entityKeyId, createdDate, createdByAlias, updatedDate, updatedByAlias, createdSystem, dfOwner, priorityAlias, linkedTcrCount, linkedRqCount, attachmentCount, componentAlias, environmentText 14. SORT FIELDS: entityKey, name, typeAlias, stateAlias, createdDate, createdByAlias, updatedDate, updatedByAlias, priorityAlias, createdSystem, linkedTcrCount, linkedRqCount, dfOwner, attachmentCount, environmentText 15. For multiple entity keys, use comma-separated values in filter 16. Use pagination for large result sets (start, page, limit parameters) 17. This tool is essential for defect management and issue tracking 18. Critical for quality assurance and defect lifecycle analysis 19. Use for compliance reporting and issue traceability 20. Helps maintain visibility into project defects and issues
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page | No | Page number to return (starts from 1) | |
| sort | No | Sort Records - refer json schema, Possible property - entityKey, name, typeAlias, stateAlias, createdDate, createdByAlias, updatedDate, updatedByAlias, priorityAlias, createdSystem, linkedTcrCount, linkedRqCount, dfOwner, attachmentCount, environmentText | [{"property":"name","direction":"ASC"}] |
| limit | No | Number of records (default 10). | |
| start | No | Start index for pagination - defaults to 0 | |
| filter | No | Filter criteria as JSON string (default '[]') | [] |
| viewId | No | ViewId for issues - SYSTEM AUTOMATICALLY RESOLVES THIS. Leave empty unless you have a specific viewId. System will fetch project info using the projectKey and extract latestViews.IS.viewId automatically. Manual viewId only needed if you want to override the automatic resolution. | |
| baseUrl | No | The base URL for the QMetry instance (must be a valid URL) | |
| projectKey | No | Project key - unique identifier for the project | default |
| isJiraIntegrated | No | Send true if current project is Integrated with Jira |