getUserGroups
Get user groups
Details
- Method:
GET - Path:
/rest/api/3/user/groups - Operation ID:
getUserGroups
Parameters
{
"accountId": {
"description": "The account ID of the user, which uniquely identifies the user across all Atlassian products. For example, *5b10ac8d82e05b22cc7d4ef5*.",
"required": true,
"location": "query",
"type": "string"
},
"username": {
"description": "This parameter is no longer available. See the [deprecation notice](https://developer.atlassian.com/cloud/jira/platform/deprecation-notice-user-privacy-api-migration-guide/) for details.",
"required": false,
"location": "query",
"type": "string"
},
"key": {
"description": "This parameter is no longer available. See the [deprecation notice](https://developer.atlassian.com/cloud/jira/platform/deprecation-notice-user-privacy-api-migration-guide/) for details.",
"required": false,
"location": "query",
"type": "string"
}
}Response Schema
{
"items": {
"additionalProperties": false,
"description": "Details about a group.",
"properties": {
"groupId": {
"description": "The ID of the group, which uniquely identifies the group across all Atlassian products. For example, *952d12c3-5b5b-4d04-bb32-44d383afc4b2*.",
"nullable": true,
"type": "string"
},
"name": {
"description": "The name of group.",
"type": "string"
},
"self": {
"description": "The URL for these group details.",
"format": "uri",
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"type": "array"
}Usage
from ocp_agent import OCPAgent
agent = OCPAgent()
await agent.register_api('jira')
# Call this tool
result = await agent.call_tool('getUserGroups', {
# Add required parameters here
})