# Zluri

> Manage the people, apps, licenses and contracts in Zluri, and run its workflows.

App · 25 actions. Web page: https://docs.lodol.com/docs/integrations/zluri

## Actions

### Add application

Add an app to your organization in Zluri.

**Inputs**

- Name (`app_name`, text, required): The app's name. It must be new in your organization.
- Owner ID (`app_owner_id`, text): The Zluri user ID of its owner.
- IT owner ID (`app_technical_owner_id`, text): The Zluri user ID of its IT owner.
- Finance owner ID (`app_financial_owner_id`, text): The Zluri user ID of its finance owner.
- Tags (`app_tags`, list): Tags to put on it.
- Type (`app_type`, text): What kind of app it is. One of: `application`, `website`, `device`, `browser`, `other`.
- Status (`app_status`, text): Whether it is active. One of: `active`, `inactive`.
- Custom fields (`app_custom_fields`, list): Custom field values, each an object with field_id and field_value. List custom fields gives the IDs.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "app_id": "6864f6532193621f61f0d2a3",
    "app_name": "New External mo",
    "message": "Application added successfully"
  }
}
```

### Add user

Add a person to your Zluri organization.

**Inputs**

- Name (`user_name`, text, required): Their full name.
- Email (`user_email`, text, required): Their work email. It must not be in Zluri already.
- Job title (`user_designation`, text): Their job title.
- Department ID (`user_department_id`, text): The Zluri ID of their department.
- Status (`user_status`, text): Their status. One of: `active`, `inactive`, `suspended`.
- Account type (`account_type`, text): What kind of account it is. One of: `employee`, `external`, `service` (Service account), `group`.
- Manager's email (`reporting_manager_email`, text): Their manager's email.
- Personal email (`user_personal_email`, text): Their personal email.
- Custom fields (`user_custom_fields`, list): Custom field values, each an object with field_id and field_value. List custom fields gives the IDs.
- Onboarding owner (`onboarding_assigned_to`, text): The user ID of who handles their onboarding.
- Onboarding date (`onboarding_date`, date): When onboarding should be done.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "message": "User added successfully",
    "user_id": "6863d6ed6a0ecaa9165f4cc5",
    "user_name": "New Testing API"
  }
}
```

### Add user to application

Record that a person uses an app.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.
- Email (`user_email`, text, required): The person's email.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "app_id": "681056ebb5c755b83e11337c",
    "message": "User added to application successfully",
    "user_id": "68921da271058fcc063ac2a5"
  }
}
```

### Find users by email

Look up people's Zluri user IDs from their primary or alternate emails.

**Inputs**

- Emails (`emails`, list, required): The email addresses to look up.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "alternate_emails": [
          "kartheek.m@zluri.com"
        ],
        "org_id": "681047a5b5c755b83e0ff97e",
        "user_email": "kartheek.m@zluri.com",
        "user_id": "68921da271058fcc063ac2a5",
        "user_name": "Kartheek M"
      }
    ]
  }
}
```

### Get application

Get an app's owners, users, licenses, contracts, spend and savings.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "active_app_user_count": 1138,
        "app_active_contracts": [
          {
            "name": "Zoom5 05 2023",
            "vendor_id": "681056eab5c755b83e113376"
          }
        ],
        "app_active_users_change": 0,
        "app_active_users_via_agents": 52,
        "app_active_users_via_direct_integration": 1138,
        "app_active_users_via_sso": 602,
        "app_annualized_costs": 0,
        "app_archive": false,
        "app_assigned_license_count": 2190,
        "app_authorization_status": "centrally managed",
        "app_budget": "0",
        "app_category": [
          {
            "category_id": "60c3488453976f714c549ba1",
            "category_name": "Collaboration & Productivity",
            "sub_category_id": "60c34debce4bf4245ff599d5",
            "sub_category_name": "Video Conferencing"
          }
        ],
        "app_chargeback_type": "default",
        "app_employee_user_count": 895,
        "app_external_user_count": 159,
        "app_financial_owner": {
          "app_financial_owner_email": "anthonyjoiner@initech.com",
          "app_financial_owner_id": "68104820b5c755b83e100567",
          "app_financial_owner_name": "Anthony Joiner"
        },
        "app_forecasted_spend": 0,
        "app_id": "681047a5b5c755b83e0ff999",
        "app_is_custom": false,
        "app_last_transaction_date": "2025-04-28 04:38:56.213+00",
        "app_last_used": "2025-09-17 01:33:21.821+00",
        "app_logo": "https://imgassets.zluri.com/applications/logos-new1/Zoom-5fc4ac5fc70ae4043c76ef7e-1625037823.png",
        "app_name": "Zoom",
        "app_next_payment_date": "2025-09-29 04:13:32.943+00",
        "app_owner": {
          "app_owner_email": "joewilson@hooli.com",
          "app_owner_id": "68104820b5c755b83e100584",
          "app_owner_name": "Joe Wilson"
        },
        "app_payment_method": [
          {
            "name": "Central bank",
            "type": "bank"
          }
        ],
        "app_spend": "0",
        "app_spend_per_month": "0",
        "app_spend_prev_fy": "27500",
        "app_status": "active",
        "app_sub_category": [
          {
            "category_id": "60c3488453976f714c549ba1",
            "category_name": "Collaboration & Productivity",
            "sub_category_id": "60c34debce4bf4245ff599d5",
            "sub_category_name": "Video Conferencing"
          }
        ],
        "app_tags": [
          "Chennai"
        ],
        "app_technical_owner": {
          "app_technical_owner_email": "concepcionjones@zluri.dev",
          "app_technical_owner_id": "6810480ab5c755b83e0ffe72",
          "app_technical_owner_name": "Concepcion Jones"
        },
        "app_threat_level": 0,
        "app_total_contract_value": 225000,
        "app_total_license_count": "0",
        "app_total_transactions": 24,
        "app_total_user_via_direct_integration": 1607,
        "app_total_users_change": 0,
        "app_total_users_via_sso": 820,
        "app_type": "website",
        "app_unassigned_license_count": "0",
        "app_usage": 0,
        "app_user_with_license_count": 1381,
        "custom_fields": [
          {
            "field_value": "",
            "org_custom_field_name": "QA Text field Audit logs",
            "org_custom_field_type": "text"
          }
        ],
        "license_utilization": {
          "annual_potential_savings": 667500,
          "annualized_realized_savings": 69000,
          "left_organisation_licenses": 749,
          "left_organisation_monthly_potential_savings": 55625,
          "monthly_potential_savings": 55625,
          "monthly_realised_savings": 5750,
          "optimizable_licenses_count": 749,
          "optimized_licenses_count": 90,
          "unused_licenses": 0,
          "unused_monthly_potential_savings": 0
        },
        "licenses": [
          {
            "license_id": "00000000-6810-51fa-b5c7-55b83e10f063",
            "license_name": "Pro"
          }
        ],
        "primary_source": [
          {
            "is_primary": true,
            "keyword": "okta",
            "org_integration_name": "Okta_0",
            "status": "active"
          }
        ],
        "source_array": [
          {
            "integration_id": "608bf15d37280ca5c38836b5",
            "is_primary": true,
            "keyword": "okta",
            "org_integration_id": "681047a5b5c755b83e0ff982",
            "org_integration_name": "Okta_0",
            "status": "active"
          }
        ],
        "source_direct_integration": "connected",
        "usage_discovered_on": "2025-04-29 03:29:41.529+00"
      }
    ],
    "meta": {
      "total": 1
    }
  }
}
```

### Get application user

Get one person's use of an app: license, cost, activity and savings.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.
- User ID (`user`, text, required): The person's Zluri user ID.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "app_id": "681047a5b5c755b83e0ff999",
        "app_name": "Zoom",
        "app_threat_level": 5,
        "current_month_spend": "0",
        "first_activity_detected": "2025-04-29 03:34:23.646+00",
        "license": [
          {
            "license_id": "681051fab5c755b83e10f063",
            "license_name": "Pro"
          }
        ],
        "license_mapped": true,
        "monthly_realized_savings": 0,
        "optimizability_reason": "",
        "optimizable_licenses": {
          "license_utilization": {
            "monthly_realized_savings": 0,
            "optimizable_licenses_count": 0,
            "optimized_licenses_count": 0
          }
        },
        "optimization_optimized_licenses": {
          "monthly_realized_savings": 0,
          "optimizable_licenses_count": 0,
          "optimized_licenses_count": 0
        },
        "optimization_potential_monthly_savings": 0,
        "user_app_annualized_cost": {
          "user_app_annualized_cost": 0
        },
        "user_app_archive": false,
        "user_app_avg_monthly_cost": {
          "user_app_avg_monthly_cost": 0
        },
        "user_app_avg_spend": {
          "user_app_avg_spend": "0",
          "user_app_avg_spend_change": "0"
        },
        "user_app_avg_usage": {
          "user_app_current_month_usage": 0
        },
        "user_app_cost_ytd": 0,
        "user_app_current_month_cost": {
          "user_app_current_month_cost": 0
        },
        "user_app_discovered": "2025-04-29 03:34:23.646+00",
        "user_app_last_used": "2025-09-16 12:46:39.219+00",
        "user_app_role_array": [
          "Owner"
        ],
        "user_app_source": [
          {
            "is_primary": true,
            "keyword": "manual"
          }
        ],
        "user_app_status": "active",
        "user_app_total_activity_past_30_days": "0",
        "user_app_total_activity_past_60_days": "0",
        "user_app_total_activity_past_90_days": "0",
        "user_app_total_spend": {
          "user_app_current_month_spend": "0",
          "user_app_total_spend": 0
        },
        "user_email": "emilyritchie@zluri.dev",
        "user_id": "6810480ab5c755b83e0ffe00",
        "user_is_optimizable": false,
        "user_name": "Emily Ritchie"
      }
    ],
    "meta": {
      "total": 1
    }
  }
}
```

### Get organization

Get your Zluri organization's name, financial year and currency.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": {
      "_id": "679b59dc315ee0a11cb4e659",
      "currency": "USD",
      "fy_end": 12,
      "fy_start": 1,
      "name": "Testing org"
    }
  }
}
```

### Get organization overview

Get this month's active users, apps, average usage and renewals, with the change from last month.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": {
      "active_users": {
        "break_down": [
          {
            "_id": "employee",
            "count": 2520
          }
        ],
        "change": 20,
        "count": 3498
      },
      "applications": {
        "break_down": [
          {
            "_id": "centrally managed",
            "count": 429
          }
        ],
        "change": 0,
        "count": 2228
      },
      "average_usage": {
        "change": 0,
        "percentage": 0
      },
      "month_id": 7,
      "renewals": {
        "change": 0,
        "count": 0
      },
      "year_id": 2025
    }
  }
}
```

### Get savings summary

Get the license savings Zluri has realized and could still realize.

**Inputs**: None.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": {
      "app_potential_savings": 48200.0,
      "app_realised_savings": 12500.5
    }
  }
}
```

### Get user

Get a person's profile, manager, department, sources, cost and app counts.

**Inputs**

- User ID (`user`, text, required): The person's Zluri user ID, from List users or Find users by email.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "applications_count": {
          "active_user_app_count": 25,
          "managed_user_app_count": 13,
          "restricted_user_app_count": 2,
          "unmanaged_user_app_count": 2,
          "user_app_count": 27
        },
        "cost_ytd": 14315.800686806417,
        "department": {
          "user_department_id": "679b59f6315ee0a11cb4e738",
          "user_department_name": "Marketing",
          "user_department_name_path": "Marketing"
        },
        "reporting_manager": {
          "user_reporting_manager_email": "shereekettler@zluri.dev",
          "user_reporting_manager_id": "679b5a0a315ee0a11cb4e764",
          "user_reporting_manager_name": "Sheree Kettler"
        },
        "source_array": [
          {
            "integration_id": "5fc27f4942ca5c5104e1df97",
            "is_primary": false,
            "keyword": "gsuite",
            "org_integration_id": "679b59dc315ee0a11cb4e65a",
            "org_integration_name": "Google Workspace_0",
            "status": "active"
          }
        ],
        "spend_ytd": 0,
        "usage": 0,
        "user": {
          "optimization_inclusion": "Included for all Optimizations",
          "user_account_type": "employee",
          "user_alternate_emails": [
            "theresawyatt@wayne.tech"
          ],
          "user_archive": false,
          "user_created_at": "2024-07-23 10:52:58.451+00",
          "user_designation": "Sales Development Associate",
          "user_email": "theresawyatt@zluri.dev",
          "user_id": "679b5a0a315ee0a11cb4e765",
          "user_name": "Theresa Wyatt",
          "user_status": "active"
        }
      }
    ],
    "meta": {
      "total": 1
    }
  }
}
```

### Get workflow run

Get a workflow run's status and how many of its actions finished, are pending or failed.

**Inputs**

- Run ID (`workflow_execution_id`, text, required): The workflow run's ID.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "completed_actions_count": 10,
    "executed_in_n8n": true,
    "executions": [
      {
        "date": "2025-05-01T01:13:55.140Z",
        "execution_id": "999999999",
        "log_refreshed": true,
        "n8n_workflow_set_up": true,
        "n8n_workflow_status": "completed",
        "origin": "first_execution",
        "type": "workflow",
        "user_email": "elizabethdevore@zluri.dev",
        "user_id": "6812c9c419ede0cfc6f4bc34",
        "user_name": "Elizabeth Devore"
      }
    ],
    "failed_actions_count": 0,
    "nodes": [
      {
        "app_id": "6812c99319ede0cfc6f49295",
        "app_logo": "https://imgassets.zluri.com/applications/logos/ServiceNow-60926083c733aa2e5d66de4f-1625037823.png",
        "app_name": "ServiceNow",
        "node_id": "6812cad319ede0cfc6f54271"
      }
    ],
    "pending_actions_count": 0,
    "run_by_user_id": "6812c9ae19ede0cfc6f49c7c",
    "run_by_user_name": "Dave Gardiner",
    "run_for_user_id": "6812c9c419ede0cfc6f4bc34",
    "run_for_user_name": "Elizabeth Devore",
    "run_timestamp": "2025-05-01T01:13:55.140Z",
    "total_actions_count": 10,
    "workflow_id": "6812cad319ede0cfc6f54284",
    "workflow_name": "offboarding execution by Dave Gardiner for ServiceNow",
    "workflow_status": "completed",
    "workflow_template_id": "6812cad319ede0cfc6f54284",
    "workflow_type": "offboarding"
  }
}
```

### List a user's apps

List the apps a person uses, with their role, licenses and last use.

**Inputs**

- User ID (`user`, text, required): The person's Zluri user ID.
- Page (`page`, number): Which page of apps to read. The first page is 0. At least 0.
- Page size (`page_size`, number): How many apps a page holds, up to 100 (Zluri's default is 50). From 1 to 100.
- Search (`search_query`, text): Only apps whose name contains this.
- Filters (`filter_by`, list): Optional filters, each an object with field_id and field_values (and field_order for dates), as Zluri's reference shows. Fields include app_status and app_type.
- Sort (`sort_by`, list): Optional sort, such as one object with a field name and 1 for ascending or -1 for descending.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "app_archive": false,
        "app_authorization_status": "centrally managed",
        "app_id": "679b59dc315ee0a11cb4e679",
        "app_name": "Azure AD",
        "app_source": [
          {
            "is_primary": true,
            "keyword": "azure",
            "org_integration_id": "679b59dc315ee0a11cb4e663",
            "org_integration_name": "Azure AD_0",
            "org_integration_status": "connected"
          }
        ],
        "app_status": "active",
        "app_type": "application",
        "custom_fields": [
          {
            "field_value": "Custom",
            "org_custom_field_name": "Abhinav Test",
            "org_custom_field_type": "text"
          }
        ],
        "license_details": [
          {
            "contract_id": "679b5f60315ee0a11cb5e69a",
            "contract_name": "Azure AD7 04 2023",
            "cost_per_quantity": 18,
            "is_optimizable": false,
            "license_assigned_on": "2025-06-25T00:00:00+00:00",
            "license_cost": 216000,
            "license_currency": "USD",
            "license_frequency": 1,
            "license_id": "679b5f60315ee0a11cb5e69d",
            "license_name": "Azure Premium P2",
            "license_period": "months",
            "start_date": "2025-06-25T00:00:00+00:00"
          }
        ],
        "user_app_archive": false,
        "user_app_discovered": "2025-01-30 10:55:53.466+00",
        "user_app_last_used": "2024-09-24 13:09:40.881+00",
        "user_app_role": "Guest",
        "user_archive": false
      }
    ],
    "meta": {
      "filter_by": [
        {
          "field_id": "user_app_status",
          "field_values": [
            "active"
          ]
        }
      ],
      "pagination": {
        "page": 0,
        "page_size": 50
      },
      "search_query": "",
      "total": 1
    }
  }
}
```

### List admins

List the people who can administer Zluri, with their role and last sign-in.

**Inputs**

- Page (`page`, number): Which page of admins to read. The first page is 0. At least 0.
- Page size (`page_size`, number): How many admins a page holds, up to 100 (Zluri's default is 30). From 1 to 100.
- Search (`search_query`, text): Only admins whose name contains this.
- Filters (`filter_by`, list): Optional filters, each an object with field_id and field_values (and field_order for dates), as Zluri's reference shows. Fields include user_name, user_email, user_status, user_role and user_last_login.
- Sort (`sort_by`, list): Optional sort, such as one object with a field name and 1 for ascending or -1 for descending.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "user_archive": false,
        "user_email": "anthonyadmin@zluri.dev",
        "user_id": "64a1b73dabc1234f00cabcde",
        "user_last_login": "2024-11-03T10:52:58.753Z",
        "user_name": "Anthony Admin",
        "user_role": "super_admin",
        "user_status": "active"
      }
    ],
    "meta": {
      "filter_by": [
        {
          "field_id": "user_role",
          "field_values": [
            "super_admin"
          ]
        }
      ],
      "pagination": {
        "page": "0",
        "page_size": "30"
      },
      "search_query": "",
      "sort_by": [
        {
          "user_name": 1
        }
      ],
      "total": 1
    }
  }
}
```

### List application licenses

List an app's licenses, or only those an access request may name.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.
- Name contains (`q`, text): Only licenses whose name contains this.
- Requestable (`requestable`, text): Only licenses a request may name, or only the rest. Leave empty for all. One of: `true` (Requestable only), `false` (Not requestable only).
- Page (`page`, number): Which page of licenses to read, starting at 1. At least 1.
- Page size (`page_size`, number): How many licenses a page holds, up to 100. From 1 to 100.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "id": "66500001a2b3c4d5e6f70002",
        "name": "Business+",
        "requestable": false,
        "type": "user"
      }
    ],
    "meta": {
      "page": 1,
      "page_size": 2,
      "total": 19
    }
  }
}
```

### List application users

List the people who use an app, with their status, license and last use.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.
- Page (`page`, number): Which page of people to read. The first page is 0. At least 0.
- Page size (`page_size`, number): How many people a page holds, up to 100 (Zluri's default is 50). From 1 to 100.
- Search (`search_query`, text): Only people whose name contains this.
- Filters (`filter_by`, list): Optional filters, each an object with field_id and field_values (and field_order for dates), as Zluri's reference shows. Fields include user_status, user_app_status, license_mapped and user_app_last_used.
- Sort (`sort_by`, list): Optional sort, such as one object with a field name and 1 for ascending or -1 for descending.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "app_instances_name": [
          "GRP_APP"
        ],
        "custom_fields": [
          {
            "field_value": "Brookschester",
            "org_custom_field_name": "City",
            "org_custom_field_type": "text"
          }
        ],
        "dept": {
          "dept_id": "679b59f6315ee0a11cb4e73d",
          "dept_name": "Sales Operations"
        },
        "dept_sub_department_1": "Sales",
        "first_activity_detected": "2025-01-30 10:56:25.327+00",
        "license_mapped": true,
        "user_account_type": "employee",
        "user_app_archive": false,
        "user_app_discovered": "2025-01-30 10:56:25.326+00",
        "user_app_last_used": "2024-09-23 13:30:07.798+00",
        "user_app_primary_source": {
          "is_primary": true,
          "keyword": "slack",
          "org_integration_id": "679b59dc315ee0a11cb4e666",
          "org_integration_name": "Slack_0",
          "org_integration_status": "connected"
        },
        "user_app_role_array": [
          "admin"
        ],
        "user_app_source": [
          {
            "is_primary": true,
            "keyword": "slack",
            "org_integration_id": "679b59dc315ee0a11cb4e666",
            "org_integration_name": "Slack_0",
            "org_integration_status": "connected"
          }
        ],
        "user_app_status": "active",
        "user_archive": false,
        "user_designation": "sales development manager",
        "user_email": "aliciaholme@zluri.dev",
        "user_id": "679b5a0a315ee0a11cb4ec81",
        "user_name": "Alicia Holme",
        "user_reporting_manager": {
          "user_id": "679b5a0a315ee0a11cb4e7a6",
          "user_name": "Katherine Williams"
        },
        "user_status": "active"
      }
    ],
    "meta": {
      "filter_by": [
        {
          "field_id": "user_app_status",
          "field_values": [
            "active"
          ]
        }
      ],
      "pagination": {
        "page": 0,
        "page_size": 50
      },
      "search_query": "Alicia Holme",
      "sort_by": [
        {
          "user_name": 1
        }
      ],
      "total": 1
    }
  }
}
```

### List applications

List the apps in your organization, with how they are managed and where Zluri found them.

**Inputs**

- Page (`page`, number): Which page of apps to read. The first page is 0. At least 0.
- Page size (`page_size`, number): How many apps a page holds, up to 100 (Zluri's default is 50). From 1 to 100.
- Search (`search_query`, text): Only apps whose name contains this.
- Filters (`filter_by`, list): Optional filters, each an object with field_id and field_values (and field_order for dates), as Zluri's reference shows. Fields include app_name, app_status, app_authorization_status and custom_fields.
- Sort (`sort_by`, list): Optional sort, such as one object with a field name and 1 for ascending or -1 for descending.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "app_archive": false,
        "app_authorization_status": "needs review",
        "app_category": [
          {
            "category_id": "60c3488453976f714c549ba2",
            "category_name": "Commerce",
            "sub_category_id": "60c34deace4bf4245ff59982",
            "sub_category_name": "Payment Processing"
          }
        ],
        "app_is_custom": false,
        "app_sub_category": [
          {
            "category_id": "60c3488453976f714c549ba2",
            "category_name": "Commerce",
            "sub_category_id": "60c34deace4bf4245ff59982",
            "sub_category_name": "Payment Processing"
          }
        ],
        "app_type": "application",
        "application": {
          "app_id": "681056ebb5c755b83e11337c",
          "app_name": "InRule"
        },
        "application_logo": "https://imgassets.zluri.com/image/561553b7-869d-4b65-b885-aaf6c062934d.jpeg",
        "application_status": "active",
        "primary_source": [
          {
            "is_primary": true,
            "keyword": "azure",
            "org_integration_name": "Azure AD_0",
            "status": "active"
          }
        ],
        "source_array": [
          {
            "integration_id": "6065e45164d9fa3b3e07b04f",
            "is_primary": true,
            "keyword": "azure",
            "org_integration_id": "679b59dc315ee0a11cb4e663",
            "org_integration_name": "Azure AD_0",
            "status": "active"
          }
        ],
        "usage_discovered_on": "2025-01-30 11:19:49.128+00"
      }
    ],
    "meta": {
      "pagination": {
        "page": 0,
        "page_size": 10
      },
      "search_query": "",
      "total": 2247
    }
  }
}
```

### List audit logs

List what people, automation rules and the system did in Zluri over a period.

**Inputs**

- From (`start_date`, date and time, required): The start of the period.
- To (`end_date`, date and time, required): The end of the period. Zluri may shorten a long range; the response says the range used.
- Page (`page`, number): Which page to read, starting at 1. At least 1.
- Page size (`page_size`, number): How many entries a page holds, up to 500. From 1 to 500.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "count": 3460,
    "end_date": "2024-02-09T08:12:05.533Z",
    "items": [
      {
        "_id": "65c098acec4db36d831b05e6",
        "actor": "user",
        "actor_id": "605072ae40973f002d004cc6",
        "actor_name": "John Doe",
        "actor_role": "admin",
        "entity": "users",
        "event": "user_login",
        "event_description": "<b>John Doe</b> was logged in on <b>2/5/2024</b>",
        "event_timestamp": "2024-02-05T08:12:31.517Z",
        "event_title": "<b>John Doe</b> was logged in",
        "event_type": "login"
      }
    ],
    "page": 1,
    "page_size": 30,
    "start_date": "2024-02-05T08:12:05.533Z"
  }
}
```

### List contracts

List your app contracts, with dates, renewal deadlines and spend.

**Inputs**

- Page (`page`, number): Which page of contracts to read. The first page is 0. At least 0.
- Page size (`page_size`, number): How many contracts a page holds, up to 100 (Zluri's default is 50). From 1 to 100.
- Search (`search_query`, text): Only contracts whose name contains this.
- Filters (`filter_by`, list): Optional filters, each an object with field_id and field_values (and field_order for dates), as Zluri's reference shows. Fields include contract_name, contract_start_date, contract_end_date and contract_auto_renews.
- Sort (`sort_by`, list): Optional sort, such as one object with a field name and 1 for ascending or -1 for descending.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "application": {
          "app_id": "681047a5b5c755b83e0ff99f",
          "app_logo": "https://imgassets.zluri.com/image/12481c66-bc10-47c6-8880-e3736ff7fdf7.jpeg",
          "app_name": "Jira",
          "app_state": "centrally managed"
        },
        "application_owner": {
          "app_owner_id": "68104820b5c755b83e100584"
        },
        "archive": false,
        "contract": {
          "archive": false,
          "contract_id": "68836206c28d243424f63f56",
          "contract_name": "Slack Contract - 24 Jul 2025"
        },
        "contract_annual_spend": "0",
        "contract_auto_renews": false,
        "contract_cancel_by": "2026-05-24T00:00:00.000Z",
        "contract_end_date": "2026-07-23T00:00:00.000Z",
        "contract_id": "68836206c28d243424f63f56",
        "contract_name": "Slack Contract - 24 Jul 2025",
        "contract_one_time_payment_date": "2025-07-30 00:00:00+00",
        "contract_payment_term": "One Time",
        "contract_payment_type": "one_time",
        "contract_renew_by": "2026-07-23T00:00:00.000Z",
        "contract_start_date": "2025-07-24T00:00:00.000Z",
        "cost": "0",
        "financials": {
          "annual_cost": "0"
        },
        "license_types": 0,
        "perpetual": {
          "perpetual_payment_date": "2025-07-30 00:00:00+00",
          "perpetual_payment_type": "one_time"
        }
      }
    ],
    "meta": {
      "filter_by": [
        {
          "field_id": "contract_start_date",
          "field_order": [
            "gte"
          ],
          "field_values": [
            "2023-10-01"
          ]
        }
      ],
      "pagination": {
        "page": 0,
        "page_size": 3
      },
      "search_query": "",
      "total": 3
    }
  }
}
```

### List custom fields

List the custom fields set up for users, apps, contracts and other records.

**Inputs**: None.

**Outputs**

- `data` (list): The custom fields, grouped by record type.

**Example output**

```json
{
  "data": [
    {
      "_id": "users",
      "custom_fields": [
        {
          "field_id": "679b613f315ee0a11cb67bd0",
          "field_name": "City",
          "field_type": "text"
        }
      ]
    }
  ]
}
```

### List requestable applications

List the apps people may request access to.

**Inputs**

- Name contains (`q`, text): Only apps whose name contains this.
- Page (`page`, number): Which page of apps to read, starting at 1. At least 1.
- Page size (`page_size`, number): How many apps a page holds, up to 100. From 1 to 100.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "app_id": "6512ab3c9f1e2d0019a7c401",
        "app_url": "https://slack.com",
        "categories": [
          {
            "category_id": "60c3488453976f714c549ba1",
            "category_name": "Collaboration & Productivity",
            "sub_category_id": "60c34debce4bf4245ff599d5",
            "sub_category_name": "Team Chat"
          }
        ],
        "description": "Team messaging and collaboration.",
        "icon_url": "https://cdn.example.com/icons/slack.png",
        "name": "Slack"
      }
    ],
    "meta": {
      "page": 1,
      "page_size": 50,
      "total": 1
    }
  }
}
```

### List users

List the people in your organization, with their department, manager, sources and usage.

**Inputs**

- Page (`page`, number): Which page of people to read. The first page is 0. At least 0.
- Page size (`page_size`, number): How many people a page holds, up to 100 (Zluri's default is 30). From 1 to 100.
- Search (`search_query`, text): Only people whose name contains this.
- Filters (`filter_by`, list): Optional filters, each an object with field_id and field_values (and field_order for dates), as Zluri's reference shows. Fields include user_status, user_account_type, user_department_id, user_archive, user_created_at and custom_fields.
- Sort (`sort_by`, list): Optional sort, such as one object with a field name and 1 for ascending or -1 for descending.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "data": [
      {
        "cost_center": {
          "user_cost_center_code": "CC 2",
          "user_cost_center_id": "64a1bf08abc1234f00cad001",
          "user_cost_center_name": "Manila",
          "user_cost_center_name_path": "Manila"
        },
        "custom_fields": [
          {
            "field_value": "North Brian",
            "org_custom_field_name": "City",
            "org_custom_field_type": "text"
          }
        ],
        "department": {
          "user_department_id": "64a1b9e4abc1234f00cabdef",
          "user_department_name": "Business Development",
          "user_department_name_path": "Sales/Business Development"
        },
        "primary_source": {
          "is_primary": true,
          "keyword": "manual",
          "status": "active"
        },
        "reporting_manager": {
          "user_reporting_manager_email": "katherinewilliams@zluri.dev",
          "user_reporting_manager_id": "64a1c22eabc1234f00cabeee",
          "user_reporting_manager_name": "Katherine Williams"
        },
        "source_array": [
          {
            "integration_id": "5fc27f4942ca5c5104e1df97",
            "is_primary": false,
            "keyword": "gsuite",
            "org_integration_id": "64a1b8f9abc1234f00cad010",
            "org_integration_name": "Google Workspace_0",
            "status": "active"
          }
        ],
        "usage": 0,
        "user": {
          "optimization_inclusion": "Included for all Optimizations",
          "user_account_type": "employee",
          "user_alternate_emails": [
            "anthonybrotherson@zluri.dev"
          ],
          "user_archive": false,
          "user_created_at": "2024-11-03 10:52:58.753+00",
          "user_designation": "business development manager",
          "user_email": "anthonybrotherson@zluri.dev",
          "user_id": "64a1b73dabc1234f00cabcde",
          "user_name": "Anthony Brotherson",
          "user_status": "active"
        }
      }
    ],
    "meta": {
      "filter_by": [
        {
          "field_id": "user_account_type",
          "field_values": [
            "employee"
          ]
        }
      ],
      "pagination": {
        "page": 0,
        "page_size": 30
      },
      "search_query": "",
      "sort_by": [
        {
          "user_name": 1
        }
      ],
      "total": 1
    }
  }
}
```

### Run workflow

Run one of your Zluri workflows, such as offboarding, for one or more people.

**Inputs**

- Workflow ID (`playbook_id`, text, required): The ID of the Zluri workflow to run.
- People (`user_emails`, list, required): The emails of the people to run it for. They must be in Zluri.
- Run by (`executed_by`, text, required): The email of the Zluri user the run is recorded against.
- Variables (`variable_data`, object): Optional values for the workflow's variables, keyed by each person's email.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "requestId": "req_0987654321fedcba",
    "status": 202,
    "success": true,
    "trackingId": "trk_1234567890abcdef"
  }
}
```

### Update application

Change an app's name, owners, tags, type, status, budget or archive state.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.
- Name (`app_name`, text): Its new name.
- Owner ID (`app_owner_id`, text): The Zluri user ID of its owner.
- IT owner ID (`app_technical_owner_id`, text): The Zluri user ID of its IT owner.
- Finance owner ID (`app_financial_owner_id`, text): The Zluri user ID of its finance owner.
- Tags (`app_tags`, list): Tags to put on it.
- Type (`app_type`, text): What kind of app it is. One of: `application`, `website`, `device`, `browser`, `other`.
- Status (`app_status`, text): Whether it is active. One of: `active`, `inactive`.
- Custom fields (`app_custom_fields`, list): Custom field values, each an object with field_id and field_value. List custom fields gives the IDs.
- Budget (`app_budget`, number): Its budget. At least 0.
- Archived (`archive`, true/false): Archive or unarchive it.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "app_id": "679b59e3315ee0a11cb4e6ad",
    "app_name": "GTZship",
    "message": "Application updated successfully!"
  }
}
```

### Update application user

Change a person's role, status, licenses or archive state in an app.

**Inputs**

- App ID (`app_id`, text, required): The app's Zluri ID, from List applications.
- User ID (`user`, text, required): The person's Zluri user ID.
- Role (`user_app_role`, text): Their role in the app.
- License optimization (`optimization_inclusion`, text): Which license optimizations they are part of. One of: `include for all optimizations` (Include in all), `exclude for all optimizations` (Exclude from all), `exclude for undeprovisioned` (Exclude from not-deprovisioned), `exclude for unused` (Exclude from unused).
- Archived (`user_app_archive`, true/false): Archive or unarchive their access.
- Licenses (`assign_licenses`, list): License IDs to assign them, from List application licenses.
- Status (`user_app_status`, text): Their status in the app. One of: `active`, `inactive`.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "app_id": "679b59f6315ee0a11cb4e73c",
    "message": "Application user updated successfully",
    "user_id": "679b5a0a315ee0a11cb4e74a"
  }
}
```

### Update user

Change a person's name, email, status, job title, department, archive state or custom fields.

**Inputs**

- User ID (`user`, text, required): The person's Zluri user ID.
- Name (`user_name`, text): Their new name.
- Email (`user_email`, text): Their new primary email.
- Status (`user_status`, text): Their status. One of: `active`, `inactive`.
- Account type (`user_account_type`, text): What kind of account it is. One of: `employee`, `external`, `service` (Service account), `group`.
- Job title (`user_designation`, text): Their job title.
- Department ID (`user_department_id`, text): The Zluri ID of their department.
- Archived (`user_archive`, true/false): Archive or unarchive them.
- Personal email (`user_personal_email`, text): Their personal email.
- License optimization (`optimization_inclusion`, text): Which license optimizations they are part of. One of: `include for all optimizations` (Include in all), `exclude for all optimizations` (Exclude from all), `exclude for undeprovisioned` (Exclude from not-deprovisioned), `exclude for unused` (Exclude from unused).
- Custom fields (`user_custom_fields`, list): Custom field values, each an object with field_id and field_value. List custom fields gives the IDs.

**Outputs**

- `data` (object): The response from Zluri.

**Example output**

```json
{
  "data": {
    "message": "User updated successfully",
    "user_id": "679b59f6315ee0a11cb4e73c"
  }
}
```
