Sanity App SDK
    Preparing search index...
    • Returns metadata for a given organisation.

      Type Parameters

      • IncludeMembers extends boolean = false
      • IncludeFeatures extends boolean = false

      Parameters

      Returns Organization<IncludeMembers, IncludeFeatures>

      The metadata for the organisation. members is included only when includeMembers: true; features is included only when includeFeatures: true.

      function OrganizationName({organizationId}: {organizationId: string}) {
      const organization = useOrganization({organizationId})

      return <h1>{organization.name}</h1>
      }
      const organizationWithMembers = useOrganization({organizationId, includeMembers: true})
      const organizationWithFeatures = useOrganization({organizationId, includeFeatures: true})