Skip to main content
POST
/
api
/
v1
/
search
/
app_users
Search
package main

import(
	"context"
	"github.com/conductorone/conductorone-sdk-go/pkg/models/shared"
	conductoronesdkgo "github.com/conductorone/conductorone-sdk-go"
	"log"
)

func main() {
    ctx := context.Background()

    s := conductoronesdkgo.New(
        conductoronesdkgo.WithSecurity(shared.Security{
            BearerAuth: "<YOUR_BEARER_TOKEN_HERE>",
            Oauth: "<YOUR_OAUTH_HERE>",
        }),
    )

    res, err := s.AppUser.Search(ctx, nil)
    if err != nil {
        log.Fatal(err)
    }
    if res.AppUserServiceSearchResponse != nil {
        // handle response
    }
}
{
  "expanded": [
    {
      "@type": "<string>"
    }
  ],
  "list": [
    {
      "appPath": "<string>",
      "appUser": {
        "appId": "<string>",
        "appUserType": "APP_USER_TYPE_UNSPECIFIED",
        "createdAt": "2023-11-07T05:31:56Z",
        "deletedAt": "2023-11-07T05:31:56Z",
        "displayName": "<string>",
        "email": "<string>",
        "emails": [
          "<string>"
        ],
        "employeeIds": [
          "<string>"
        ],
        "id": "<string>",
        "identityUserId": "<string>",
        "isExternal": true,
        "profile": {},
        "status": {
          "details": "<string>",
          "status": "STATUS_UNSPECIFIED"
        },
        "updatedAt": "2023-11-07T05:31:56Z",
        "username": "<string>",
        "usernames": [
          "<string>"
        ]
      },
      "identityUserPath": "<string>",
      "lastUsagePath": "<string>"
    }
  ],
  "nextPageToken": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Authorization
string
header
required

This API uses OAuth2 with the Client Credential flow. Client Credentials must be sent in the BODY, not the headers. For an example of how to implement this, refer to the c1TokenSource.Token() function.

Body

application/json

Search App users based on filters specified in the request body

appId
string

The app ID to restrict the search to.

appUserDomains
enum<string>[] | null

A list of account domains to restrict the search to.

Available options:
APP_USER_DOMAIN_UNSPECIFIED,
APP_USER_DOMAIN_EXTERNAL,
APP_USER_DOMAIN_TRUSTED
appUserIds
string[] | null

A list of app user IDs to restrict the search to.

appUserStatusDetails
string[] | null

A list of app user status details to restrict the search to.

appUserStatuses
enum<string>[] | null

A list of app user statuses to restrict the search to.

Available options:
STATUS_UNSPECIFIED,
STATUS_ENABLED,
STATUS_DISABLED,
STATUS_DELETED
appUserTypes
enum<string>[] | null

A list of app user types to restrict the search to.

Available options:
APP_USER_TYPE_UNSPECIFIED,
APP_USER_TYPE_USER,
APP_USER_TYPE_SERVICE_ACCOUNT,
APP_USER_TYPE_SYSTEM_ACCOUNT
excludeAppUserIds
string[] | null

A list of app user IDs to remove from the results.

expandMask
App User Expand Mask · object

The AppUserExpandMask message contains a list of paths to expand in the response.

pageSize
integer<int32>

The pageSize where 0 <= pageSize <= 100. Values < 10 will be set to 10. A value of 0 returns the default page size (currently 25)

pageToken
string

The pageToken field.

query
string

Query the apps with a fuzzy search on display name and description.

refs
App User Ref · object[] | null

A list of app users to limit the search to.

userIds
string[] | null

A list of user IDs to restrict the search by.

Response

200 - application/json

Successful response

The AppUserServiceSearchResponse message.

expanded
object[] | null

List of related objects.

list
App User View · object[] | null

The list of results containing up to X results, where X is the page size defined in the request.

nextPageToken
string

The nextPageToken is shown for the next page if the number of results is larger than the max page size. The server returns one page of results and the nextPageToken until all results are retrieved. To retrieve the next page, use the same request and append a pageToken field with the value of nextPageToken shown on the previous page.