POST /api/workflows/mget

Spaces method and path for this operation:

post /s/{space_id}/api/workflows/mget

Refer to Spaces for more information.

Retrieve multiple workflows by their IDs in a single request. Optionally use the source parameter to return only specific fields from each workflow document.

[Required authorization] Route required privileges: workflowsManagement:read.

Headers

  • kbn-xsrf string Required

    A required header to protect against CSRF attacks

application/json

Body

  • ids array[string] Required

    Array of workflow IDs to look up.

    At least 1 but not more than 500 elements. Maximum length of each is 255.

  • source array[string]

    Array of source fields to include.

    At least 1 but not more than 10 elements. Maximum length of each is 255.

Responses

  • 200 application/json

    Indicates a successful response

POST /api/workflows/mget
curl \
  -X POST "${KIBANA_URL}/api/workflows/mget" \
  -H "Authorization: ApiKey ${API_KEY}" \
  -H "kbn-xsrf: true" \
  -H "Content-Type: application/json" \
  -d '{
    "ids": ["workflow-a1b2c3d4-e5f6-7890-abcd-ef1234567890", "workflow-b2c3d4e5-f6a7-8901-bcde-f12345678901"],
    "source": ["name", "enabled"]
  }'
POST kbn://api/workflows/mget
{
  "ids": ["workflow-a1b2c3d4-e5f6-7890-abcd-ef1234567890", "workflow-b2c3d4e5-f6a7-8901-bcde-f12345678901"],
  "source": ["name", "enabled"]
}
Request example
Example request to retrieve multiple workflows by their IDs
{
  "ids": [
    "workflow-a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "workflow-b2c3d4e5-f6a7-8901-bcde-f12345678901"
  ],
  "source": [
    "name",
    "enabled"
  ]
}
Response examples (200)
Example response returning the requested workflows with projected fields
[
  {
    "id": "workflow-a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "name": "Example definition",
    "enabled": true
  },
  {
    "id": "workflow-b2c3d4e5-f6a7-8901-bcde-f12345678901",
    "name": "Second workflow",
    "enabled": false
  }
]