Method: projects.locations.completeExternalIdentities

This method provides suggestions for users and groups managed in an external identity provider, based on the provided prefix.

HTTP request

GET https://discoveryengine.googleapis.com/v1alpha/{parent=projects/*/locations/*}:completeExternalIdentities

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
parent

string

Required. The parent location resource name, such as projects/*/locations/global.

Query parameters

Parameters
prefixQuery

string

Required. The prefix to search for. For users, this prefix is matched against the primaryEmail. For groups, this prefix is matched against the displayName. The matching is case-insensitive.

maxSuggestions

integer

Optional. The maximum number of user and group results to return. The service may return fewer than this value.

If unspecified, at most 6 results will be returned. The limit is distributed as evenly as possible across users and groups. For example, if maxSuggestions is 7, the service may return 4 users and 3 groups. If there are fewer suggestions of one type than half the limit, the other type may return more suggestions up to the maxSuggestions limit.

entityTypeFilter

enum (EntityTypeFilter)

Optional. The type of entities to fetch. If not set, all entity types will be returned.

useScimIdentities

boolean

Optional. Whether to use scim identities for external identity completion. If false, we will call the Microsoft graph API to fetch the external identities.

Request body

The request body must be empty.

Response body

Response message for CompletionService.CompleteExternalIdentities.

If successful, the response body contains data with the following structure:

JSON representation
{
  "externalIdentities": [
    {
      object (ExternalIdentity)
    }
  ]
}
Fields
externalIdentities[]

object (ExternalIdentity)

The list of external identities that match the query.

Authorization scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/cloud-platform
  • https://www.googleapis.com/auth/discoveryengine.readwrite
  • https://www.googleapis.com/auth/discoveryengine.assist.readwrite

For more information, see the Authentication Overview.

IAM Permissions

Requires the following IAM permission on the parent resource:

  • discoveryengine.locations.completeExternalIdentities

For more information, see the IAM documentation.

EntityTypeFilter

The type of entities to fetch.

Enums
ENTITY_TYPE_FILTER_UNSPECIFIED Unspecified entity type filter.
USERS Fetch only users.
GROUPS Fetch only groups.

ExternalIdentity

External identity representing either a user or group. This user or group is from an external identity provider (IdP).

JSON representation
{
  "externalId": string,
  "displayName": string,

  // Union field EntityType can be only one of the following:
  "userMetadata": {
    object (UserMetadata)
  },
  "groupMetadata": {
    object (GroupMetadata)
  }
  // End of list of possible types for union field EntityType.
}
Fields
externalId

string

The unique 3P id(externalId) of the entity (user or group).

displayName

string

The display name of the user or group.

Union field EntityType. The type of the external identity. This is used to indicate the type of entity (user or group) and the corresponding metadata. EntityType can be only one of the following:
userMetadata

object (UserMetadata)

metadata corresponding to the external user.

groupMetadata

object (GroupMetadata)

metadata corresponding to the external user.

UserMetadata

metadata corresponding to the external user.

JSON representation
{
  "givenName": string,
  "familyName": string,
  "primaryEmail": string
}
Fields
givenName

string

The user's given name.

familyName

string

The user's family name.

primaryEmail

string

The user's primary email address.

GroupMetadata

This type has no fields.

metadata corresponding to the external group.