Skip to main content
GET
/
v2
/
workflows
PHP
declare(strict_types=1);

require 'vendor/autoload.php';

use novu;
use novu\Models\Operations;

$sdk = novu\Novu::builder()
    ->setSecurity(
        'YOUR_SECRET_KEY_HERE'
    )
    ->build();

$request = new Operations\WorkflowControllerSearchWorkflowsRequest(
    limit: 10,
    offset: 0,
);

$response = $sdk->workflows->list(
    request: $request
);

if ($response->listWorkflowResponse !== null) {
    // handle response
}
{
  "workflows": [
    {
      "name": "<string>",
      "updatedAt": "<string>",
      "createdAt": "<string>",
      "_id": "<string>",
      "workflowId": "<string>",
      "slug": "<string>",
      "stepTypeOverviews": [],
      "steps": [
        {
          "slug": "<string>",
          "issues": {
            "controls": {},
            "integration": {}
          }
        }
      ],
      "tags": [
        "<string>"
      ],
      "updatedBy": {
        "_id": "<string>",
        "firstName": "<string>",
        "lastName": "<string>",
        "externalId": "<string>"
      },
      "lastPublishedAt": "<string>",
      "lastPublishedBy": {
        "_id": "<string>",
        "firstName": "<string>",
        "lastName": "<string>",
        "externalId": "<string>"
      },
      "lastTriggeredAt": "<string>",
      "isTranslationEnabled": true
    }
  ],
  "totalCount": 123
}

Authorizations

Authorization
string
header
required

API key authentication. Allowed headers-- "Authorization: ApiKey <novu_secret_key>".

Headers

idempotency-key
string

A header for idempotency purposes

Query Parameters

limit
number

Number of items to return per page

offset
number

Number of items to skip before starting to return results

orderDirection
enum<string>

Direction of sorting

Available options:
ASC,
DESC
orderBy
enum<string>

Field to sort the results by

Available options:
createdAt,
updatedAt,
name,
lastTriggeredAt
query
string

Search query to filter workflows

tags
string[]

Filter workflows by tags

status
enum<string>[]

Filter workflows by status

Status of the workflow

Available options:
ACTIVE,
INACTIVE,
ERROR

Response

OK

workflows
object[]
required

List of workflows

totalCount
number
required

Total number of workflows