---
schema_version: "1"
id: 521d53c42caffc68c91c95e15ef26c56f5252ab502897489dbb722a4710ea788
title: managers
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/sales/264-0-0/spiff_function_ref_managers.md
canonical_url: https://help.salesforce.com/s/articleView?id=sales.spiff_function_ref_managers.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 7acea6c85fd10ab2e074cfdd4a0812838514f22c597e66020883766462916935
description: Returns a list of user objects for managers of one or more teams in Salesforce Spiff, based on a specific date range and levels of team hierarchy. To return team members and managers, use the members() function.
products:
  - Sales Cloud
  - Sales Enablement
release: "264"
---
# managers

Returns a list of user objects for managers of one or more teams in Salesforce Spiff, based on a specific date range and levels of team hierarchy. To return team members and managers, use the `members()` function.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: both Salesforce Classic (not available in all orgs) and Lightning Experience</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: <strong>Enterprise</strong>, <strong>Unlimited</strong>, and <strong>Developer</strong> Editions</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available for an additional cost in: <strong>Professional</strong> Edition with Web Services API Enabled</td></tr></tbody></table>

## Syntax

```
managers(team_or_teams, date_or_date_range, level_or_level_range)
```

## Arguments

  
| Argument | Required? | Description |
| --- | --- | --- |
| team\_or\_teams | Required | A team or list of teams. Enclose team names in double quotes, exactly as they appear on the Teams page in Spiff. For a list of teams, enclose the list in brackets and separate values with commas, such as `["Team A", "Team B"]`. |
| date\_or\_date\_range | Optional | The time period for the team data. If you specify an individual date, this function uses the beginning and end of the day for the date range. To specify a range of dates, enclose a list in brackets and separate values with commas, such as `[BeginningOfYear, date("2025-02-01")]`. This argument supports other date functions. The default value is `all`, which returns all managers that have ever been part of the team or teams. |
| level\_or\_level\_range | Optional | An integer that specifies the number of levels in the team hierarchy, relative to team\_or\_teams, to return manager records for. To move up in the team hierarchy, specify a negative value. The default value is `0`, which means that the function returns only direct managers for the team\_or\_teams. To specify a range of levels, starting with the highest level, enclose a list in brackets and separate values with commas, such as `[-1, 1]`. |

## Examples

Return the managers for Team A and Team B for the first half of the year.

```
=managers(["Team A", "Team B"], [date("2024-01-01"), date("2024-06-30")])
```

Return the current managers for the team above Team A in the hierarchy.

```
=managers("Team A", Today, -1)
```

Return managers one level above and one level below Team A.

```
=managers("Team A", Today, [-1, 1])
```

#### See Also

- [members](https://help.salesforce.com/s/articleView?id=sales.spiff_function_ref_members.htm&release=264.0.0&type=5 "Returns a list of user objects for users who belong to one or more teams in Salesforce Spiff, based on a specific date range and levels of team hierarchy. Optionally return both managers and team members or team members only. To return managers only, use the managers() function.")