> ## Documentation Index
> Fetch the complete documentation index at: https://conductorone-docs-mcp-bridge-private-server.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Search Graph

> SearchGraph performs a server-side BFS traversal and returns a bounded, filtered subgraph.
 Exactly one of user_id, app_id, or resource_id must be set.



## OpenAPI

````yaml https://spec.speakeasy.com/conductor-one/conductorone/my-source-with-code-samples post /api/v1/search/graph
openapi: 3.1.0
info:
  description: The C1 API is a HTTP API for managing C1 resources.
  title: C1 API
  version: 0.1.0-alpha
servers:
  - description: The C1 API server for the current tenant.
    url: https://{tenantDomain}.conductor.one
    variables:
      tenantDomain:
        default: example
        description: The domain of the tenant to use for this request.
security:
  - bearerAuth: []
    oauth: []
paths:
  /api/v1/search/graph:
    post:
      tags:
        - App Entitlement
      summary: Search Graph
      description: >-
        SearchGraph performs a server-side BFS traversal and returns a bounded,
        filtered subgraph.
         Exactly one of user_id, app_id, or resource_id must be set.
      operationId: c1.api.app.v1.AppEntitlementSearchService.SearchGraph
      requestBody:
        content:
          application/json:
            schema:
              $ref: >-
                #/components/schemas/c1.api.app.v1.AppEntitlementSearchServiceSearchGraphRequest
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/c1.api.app.v1.AppEntitlementSearchServiceSearchGraphResponse
          description: SearchGraph response. Contains a subgraph of nodes and edges.
      x-codeSamples:
        - lang: typescript
          label: Typescript (SDK)
          source: >-
            import { ConductoroneSDKTypescript } from
            "conductorone-sdk-typescript";


            const conductoroneSDKTypescript = new ConductoroneSDKTypescript({
              security: {
                bearerAuth: "<YOUR_BEARER_TOKEN_HERE>",
                oauth: "<YOUR_OAUTH_HERE>",
              },
            });


            async function run() {
              const result = await conductoroneSDKTypescript.appEntitlementSearch.searchGraph();

              console.log(result);
            }


            run();
components:
  schemas:
    c1.api.app.v1.AppEntitlementSearchServiceSearchGraphRequest:
      description: >-
        SearchGraph request. Builds a filtered access graph starting from a root
        entity.
         Exactly one of user_id, app_id, or resource_id must be set.
         Server validates this constraint and returns InvalidArgument if violated.
      properties:
        appId:
          description: The appId field.
          type:
            - string
            - 'null'
        appIds:
          description: Filters — all optional, applied at every traversal hop
          items:
            type: string
          type:
            - array
            - 'null'
        entitlementIds:
          description: The entitlementIds field.
          items:
            type: string
          type:
            - array
            - 'null'
        entitlementNameQuery:
          description: The entitlementNameQuery field.
          type:
            - string
            - 'null'
        maxDepth:
          description: Traversal controls
          format: int32
          type:
            - integer
            - 'null'
        maxFanOut:
          description: The maxFanOut field.
          format: int32
          type:
            - integer
            - 'null'
        pageSize:
          description: The pageSize field.
          format: int32
          type:
            - integer
            - 'null'
        pageToken:
          description: The pageToken field.
          type:
            - string
            - 'null'
        resourceId:
          description: The resourceId field.
          type:
            - string
            - 'null'
        resourceIds:
          description: The resourceIds field.
          items:
            type: string
          type:
            - array
            - 'null'
        resourceNameQuery:
          description: The resourceNameQuery field.
          type:
            - string
            - 'null'
        resourceTypeIds:
          description: The resourceTypeIds field.
          items:
            type: string
          type:
            - array
            - 'null'
        userId:
          description: Root entity — exactly one must be set
          type:
            - string
            - 'null'
      title: App Entitlement Search Service Search Graph Request
      type: object
      x-speakeasy-name-override: AppEntitlementSearchServiceSearchGraphRequest
    c1.api.app.v1.AppEntitlementSearchServiceSearchGraphResponse:
      description: SearchGraph response. Contains a subgraph of nodes and edges.
      properties:
        edges:
          description: The edges field.
          items:
            $ref: '#/components/schemas/c1.api.app.v1.GraphEdge'
          type:
            - array
            - 'null'
        hasMore:
          description: The hasMore field.
          type:
            - boolean
            - 'null'
        nodes:
          description: The nodes field.
          items:
            $ref: '#/components/schemas/c1.api.app.v1.GraphNode'
          type:
            - array
            - 'null'
        pageToken:
          description: The pageToken field.
          type:
            - string
            - 'null'
        pathsReturned:
          description: The pathsReturned field.
          format: int32
          type:
            - integer
            - 'null'
        truncatedNodeIds:
          description: The truncatedNodeIds field.
          items:
            type: string
          type:
            - array
            - 'null'
      title: App Entitlement Search Service Search Graph Response
      type: object
      x-speakeasy-name-override: AppEntitlementSearchServiceSearchGraphResponse
    c1.api.app.v1.GraphEdge:
      description: An edge in the access graph.
      properties:
        hiddenChildren:
          description: The hiddenChildren field.
          format: int32
          type:
            - integer
            - 'null'
        isTruncated:
          description: The isTruncated field.
          type:
            - boolean
            - 'null'
        sourceId:
          description: The sourceId field.
          type:
            - string
            - 'null'
        targetId:
          description: The targetId field.
          type:
            - string
            - 'null'
        type:
          description: The type field.
          enum:
            - GRAPH_EDGE_TYPE_UNSPECIFIED
            - GRAPH_EDGE_TYPE_IDENTITY_LINK
            - GRAPH_EDGE_TYPE_DIRECT_GRANT
            - GRAPH_EDGE_TYPE_APP_HIERARCHY
            - GRAPH_EDGE_TYPE_RESOURCE_HIERARCHY
            - GRAPH_EDGE_TYPE_PROXY_BINDING
          type:
            - string
            - 'null'
          x-speakeasy-unknown-values: allow
      title: Graph Edge
      type: object
      x-speakeasy-name-override: GraphEdge
    c1.api.app.v1.GraphNode:
      description: A node in the access graph.
      properties:
        appId:
          description: The appId field.
          type:
            - string
            - 'null'
        displayName:
          description: The displayName field.
          type:
            - string
            - 'null'
        id:
          description: The id field.
          type:
            - string
            - 'null'
        resourceTypeId:
          description: The resourceTypeId field.
          type:
            - string
            - 'null'
        type:
          description: The type field.
          enum:
            - GRAPH_NODE_TYPE_UNSPECIFIED
            - GRAPH_NODE_TYPE_USER
            - GRAPH_NODE_TYPE_APP_USER
            - GRAPH_NODE_TYPE_APP
            - GRAPH_NODE_TYPE_RESOURCE_TYPE
            - GRAPH_NODE_TYPE_RESOURCE
            - GRAPH_NODE_TYPE_ENTITLEMENT
            - GRAPH_NODE_TYPE_GRANT
          type:
            - string
            - 'null'
          x-speakeasy-unknown-values: allow
      title: Graph Node
      type: object
      x-speakeasy-name-override: GraphNode
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http
    oauth:
      description: >-
        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()](https://github.com/ConductorOne/conductorone-sdk-go/blob/3375fe7c0126d17e7ec4e711693dee7b791023aa/token_source.go#L101-L187)
        function.
      flows:
        clientCredentials:
          scopes: {}
          tokenUrl: /auth/v1/token
      type: oauth2

````