Open Context Protocol is live! 🚀 Read the launch post
getPrecomputationsById

getPrecomputationsById

Get precomputations by ID (apps)

Details

  • Method: POST
  • Path: /rest/api/3/jql/function/computation/search
  • Operation ID: getPrecomputationsByID

Parameters

{
  "orderBy": {
    "description": "[Order](#ordering) the results by a field:\n\n *  `functionKey` Sorts by the functionKey.\n *  `used` Sorts by the used timestamp.\n *  `created` Sorts by the created timestamp.\n *  `updated` Sorts by the updated timestamp.",
    "required": false,
    "location": "query",
    "type": "string"
  },
  "precomputationIDs": {
    "description": "",
    "required": false,
    "location": "body",
    "type": "array"
  }
}

Response Schema

{
  "additionalProperties": false,
  "description": "Get precomputations by ID response.",
  "properties": {
    "notFoundPrecomputationIDs": {
      "description": "List of precomputations that were not found.",
      "items": {
        "readOnly": true,
        "type": "string"
      },
      "readOnly": true,
      "type": "array"
    },
    "precomputations": {
      "description": "The list of precomputations.",
      "items": {
        "additionalProperties": false,
        "description": "Jql function precomputation.",
        "properties": {
          "arguments": {
            "description": "The list of arguments function was invoked with.",
            "items": {
              "readOnly": true,
              "type": "string"
            },
            "readOnly": true,
            "type": "array"
          },
          "created": {
            "description": "The timestamp of the precomputation creation.",
            "format": "date-time",
            "readOnly": true,
            "type": "string"
          },
          "error": {
            "description": "The error message to be displayed to the user.",
            "readOnly": true,
            "type": "string"
          },
          "field": {
            "description": "The field the function was executed against.",
            "readOnly": true,
            "type": "string"
          },
          "functionKey": {
            "description": "The function key.",
            "readOnly": true,
            "type": "string"
          },
          "functionName": {
            "description": "The name of the function.",
            "readOnly": true,
            "type": "string"
          },
          "id": {
            "description": "The id of the precomputation.",
            "readOnly": true,
            "type": "string"
          },
          "operator": {
            "description": "The operator in context of which function was executed.",
            "readOnly": true,
            "type": "string"
          },
          "updated": {
            "description": "The timestamp of the precomputation last update.",
            "format": "date-time",
            "readOnly": true,
            "type": "string"
          },
          "used": {
            "description": "The timestamp of the precomputation last usage.",
            "format": "date-time",
            "readOnly": true,
            "type": "string"
          },
          "value": {
            "description": "The JQL fragment stored as the precomputation.",
            "readOnly": true,
            "type": "string"
          }
        },
        "type": "object"
      },
      "readOnly": true,
      "type": "array"
    }
  },
  "type": "object"
}

Usage

from ocp_agent import OCPAgent

agent = OCPAgent()
await agent.register_api('jira')

# Call this tool
result = await agent.call_tool('getPrecomputationsById', {
    # Add required parameters here
})